Explain how to install dds locally and use shorter require statements.

This commit is contained in:
Sergiu Ivanov 2020-05-16 00:01:36 +02:00
parent 82def3b704
commit c5d2ff629c

View file

@ -1,6 +1,6 @@
#+TITLE: Examples of usage of =dds=
#+PROPERTY: header-args:racket :prologue "#lang racket\n(require graph (file \"~/Candies/prj/racket/dds/networks.rkt\") (file \"~/Candies/prj/racket/dds/utils.rkt\"))"
#+PROPERTY: header-args:racket :prologue "#lang racket\n(require graph dds/networks.rkt dds/utils.rkt)"
* Introduction
This document shows some examples of usage of the modules in =dds=
@ -15,7 +15,23 @@
submodules of =dds=.
* Org-mode, Racket, and =dds= <<intro>>
** Importing a module from file
** Installing =dds= locally
To install =dds= locally, you can simply run the following command
in [[/home/scolobb/Candies/prj/racket/dds/][=dds=]].
#+BEGIN_SRC shell
raco pkg install
#+END_SRC
After this installation, you can import =dds= modules by simply
doing the following:
#+BEGIN_SRC racket :results output drawer
#lang racket
(file dds/networks)
(file dds/utils)
#+END_SRC
** Importing a module from file :old:
:PROPERTIES:
:header-args:racket: :prologue "#lang racket\n(require (file \"~/Candies/prj/racket/dds/networks.rkt\"))"
:END:
@ -655,7 +671,7 @@ tab
* Reaction systems
:PROPERTIES:
:header-args:racket: :prologue "#lang racket\n(require graph (file \"~/Candies/prj/racket/dds/rs.rkt\") (file \"~/Candies/prj/racket/dds/utils.rkt\"))"
:header-args:racket: :prologue "#lang racket\n(require graph dds/rs dds/utils)"
:END:
Consider the following reaction system:
#+NAME: rs1