Skip to content

Commit bca482a

Browse files
committed
add examples
1 parent e11ac63 commit bca482a

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

examples/test_fastcore.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/usr/bin/env python
2+
3+
from fastcore.script import *
4+
@call_parse
5+
def main(msg:Param("The message", str),
6+
upper:Param("Convert to uppercase?", store_true)):
7+
"Print `msg`, optionally converting to uppercase"
8+
print(msg.upper() if upper else msg)

0 commit comments

Comments
 (0)