FRENPY is a french version of python
Project description
frenpy
frenpy est une bibliothèque permettant d'exécuter des scripts Python écrits en français.
Installation
Pour installer la bibliothèque, utilisez pip :
pip install frenpy
Importation
Pour importer la bibliothèque dans votre script Python :
import frenpy
Fonctionnalités
Compiler un fichier .frenpy en .py
La fonction compile_frenpy permet de transformer un fichier .frenpy en code Python.
data_compiled = frenpy.compile_frenpy(filepath)
Charger et exécuter un fichier compilé .frenpy ou .py
La fonction load permet de charger et d'exécuter un fichier .frenpy ou .py.
frenpy.load(filepath)
Exécuter des fichiers .py ou .frenpy de manière interactive
La fonction main_function permet de lancer des fichiers .py ou .frenpy de manière interactive.
frenpy.main_function()
Syntaxe des fichiers .frenpy
Les fichiers .frenpy sont des scripts Python écrits en français. Voici la liste des mots-clés traduits :
def => définir
import => importer
print => afficher
if => si
else => sinon
while True => répéter à l'infini
round => arrondir
os.system("cls") => nouvelle écran
break => stopper
time.sleep => attendre
input => saisir
in => dans la
retourner => return
et => and
ou => or
non => not
vrai => True
faux => False
pour => for
tant que => while
essayer => try
except => except
avec => with
classe => class
importer comme => import as
depuis => from
lever => raise
continuer => continue
passer => pass
supprimer => del
global => global
lambda => lambda
assurer => assert
ranger => sort
longueur => len
ouvrir => open
liste => list
dictionnaire => dict
ensemble => set
tuple => tuple
enumerer => enumerate
toutes => all
n'importe lequel => any
plage => range
type => type
frpy_info => affiche la version actuel
frpy_scc=True => sauvegarde la version compilée
frpy_debug=true => active le debug
*Tout les mots commençant par frpy ne sont pas transformable en python car ils n'ont pas de traduction littéral
Exemple
Voici un exemple de fichier .frenpy :
# importations :
importer os
importer time
# configuration de frenpy :
frpy_debug=True
frpy_scc=True
# test de la fonction :
afficher("--- version de frpy ---")
frpy_info
afficher("-----------------------")
attendre(3)
afficher("Bonjour, ce texte est un exemple")
# test interaction
question = saisir("es-tu riche ?")
si "oui" dans la question :
afficher("tu es riche !")
si "non" dans la question:
afficher("tu n'es pas riche !")
Contributeurs
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file frenpy-0.3.6.tar.gz.
File metadata
- Download URL: frenpy-0.3.6.tar.gz
- Upload date:
- Size: 4.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8677d0294537a7ed109272a0158c1bac6859b354c886ba519452adb7678bc9ed
|
|
| MD5 |
768a66e6992fe65702eee38e5485499e
|
|
| BLAKE2b-256 |
859764dbe7f185077c5ff12ed81a54c2f1cc241a6ad1c4df152b907ad36b9560
|
Provenance
The following attestation bundles were made for frenpy-0.3.6.tar.gz:
Publisher:
python-publish.yml on slohwnix/frenPY
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
frenpy-0.3.6.tar.gz -
Subject digest:
8677d0294537a7ed109272a0158c1bac6859b354c886ba519452adb7678bc9ed - Sigstore transparency entry: 159346189
- Sigstore integration time:
-
Permalink:
slohwnix/frenPY@313daaa23d4411eae300644142d7ea0219cf34df -
Branch / Tag:
refs/tags/Beta_0.3.6 - Owner: https://github.com/slohwnix
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@313daaa23d4411eae300644142d7ea0219cf34df -
Trigger Event:
release
-
Statement type:
File details
Details for the file FRENPY-0.3.6-py3-none-any.whl.
File metadata
- Download URL: FRENPY-0.3.6-py3-none-any.whl
- Upload date:
- Size: 5.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7357be183c315901337103e2238ac1f0a366d9bae37847130c015b26b09372d6
|
|
| MD5 |
aa4f6b20e6e771c17ef99e05e2ddba31
|
|
| BLAKE2b-256 |
139cb3492a4c9a567d70c9b9aed4b71029c07c6f63ec82366fbe634d3c5f4b02
|
Provenance
The following attestation bundles were made for FRENPY-0.3.6-py3-none-any.whl:
Publisher:
python-publish.yml on slohwnix/frenPY
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
frenpy-0.3.6-py3-none-any.whl -
Subject digest:
7357be183c315901337103e2238ac1f0a366d9bae37847130c015b26b09372d6 - Sigstore transparency entry: 159346191
- Sigstore integration time:
-
Permalink:
slohwnix/frenPY@313daaa23d4411eae300644142d7ea0219cf34df -
Branch / Tag:
refs/tags/Beta_0.3.6 - Owner: https://github.com/slohwnix
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@313daaa23d4411eae300644142d7ea0219cf34df -
Trigger Event:
release
-
Statement type: