python with braces.
Project description
nestpy
"what if python, with braces, one line?"
SETUP
Install nestpy by executing:
$ pip install nestpython
After importing;
-
In order to compile a string from nestpy to python, use
nestpy.ncompile(string)
-
In order to execute a nestpy string, use
nestpy.nexec(string)
For both, optional argument
indent-level
determines the indentation increment in the resulting python file. It is set to 1 by default. -
To execute and compile files and folders, use the
nestpy.files
module:nestpy.files.ncompile(file)
compiles the given file to a stringnestpy.files.nexec(file)
executes the filenestpy.files.build(dir, new_dir)
builds an entire golder- arguments can be provided.
FEATURING:
braces
Use {
, ;
and }
instead of indentation! Indentation and newlines in the source files will be ignored. e.g.:
n = input('Enter Number: ');
if (n % 2 == 0) {
print('n is even')
} else {
print('n is odd')
}
(to be continued)
github : https://github.com/slycedf/nestpy
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file nestpython-0.3.7.tar.gz
.
File metadata
- Download URL: nestpython-0.3.7.tar.gz
- Upload date:
- Size: 6.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 217efdcb7abd72a3d8dba277dccd2d542febe3bc342874b76680797982033410 |
|
MD5 | 23a78b8af26cadd6d972f2cf613f85c0 |
|
BLAKE2b-256 | 638c9499ddf93bd2b75a90aba8cb2916b2cee28b792b4afb1db9980b310c073f |
File details
Details for the file nestpython-0.3.7-py3-none-any.whl
.
File metadata
- Download URL: nestpython-0.3.7-py3-none-any.whl
- Upload date:
- Size: 6.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c90c4f71c35576ab43f7b2fbd4c1100a05ecb107e460e5ec6a79599e6d471b1d |
|
MD5 | cdc071204cb61d25cfcc6fd02eeb8229 |
|
BLAKE2b-256 | cff4b5574e740281dc7fcaf70a36a6de6a56f39c70648e6bb01591c69ecd24e8 |