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.11.tar.gz
.
File metadata
- Download URL: nestpython-0.3.11.tar.gz
- Upload date:
- Size: 6.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a3386d1f4b4612194d66fc5f6e78ac286e4874bc8231708d5c5845995200d0b9 |
|
MD5 | 104c10cb481edb0c65b46da85123d1c9 |
|
BLAKE2b-256 | 4df1323a1b027b3cfe0be83bed8632fe876951a22e55e316a1024014b7335aae |
File details
Details for the file nestpython-0.3.11-py3-none-any.whl
.
File metadata
- Download URL: nestpython-0.3.11-py3-none-any.whl
- Upload date:
- Size: 6.4 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 | 883049e41b2fbe39e196dc880f2f7f0a6c044cca1054bcf1eb4220455b4a3b30 |
|
MD5 | 89d4ab3833bfd65b5bd0c84092bdbde9 |
|
BLAKE2b-256 | 106d7016109273cd445ec27e7d46a317a9d322edf0caee188c29352a643bdbe3 |