mirror of
https://github.com/vishapoberon/oberonbyexample.git
synced 2026-04-05 21:02:25 +00:00
added readme; -- noch
This commit is contained in:
parent
74f731e752
commit
33286378b9
1 changed files with 46 additions and 0 deletions
46
arguments/unixstyle_oberon_traditional/readme.md
Normal file
46
arguments/unixstyle_oberon_traditional/readme.md
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
|
||||
example shows how to implement unix style arguments parsing by using traditional oberon functions from modules Texts and Oberon.
|
||||
|
||||
compile
|
||||
=======
|
||||
|
||||
```
|
||||
make
|
||||
```
|
||||
|
||||
run
|
||||
===
|
||||
|
||||
```
|
||||
make test
|
||||
```
|
||||
|
||||
or type
|
||||
|
||||
```
|
||||
./partest -str aaa -int 111
|
||||
```
|
||||
|
||||
that should produce the following output
|
||||
|
||||
```
|
||||
hello, world, let's see which arguments do we get
|
||||
key: str
|
||||
value: aaa
|
||||
key: int
|
||||
value: 111
|
||||
```
|
||||
|
||||
```
|
||||
./partest -str 000 -int 111
|
||||
```
|
||||
|
||||
the output will be
|
||||
|
||||
```
|
||||
hello, world, let's see which arguments do we get
|
||||
key: str
|
||||
string expected
|
||||
Terminated by Halt(1).
|
||||
```
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue