1
0
Fork 0
Traduction de la documentation de Python en français.
Go to file
Julien Palard ed5f843dc3 First try playing with pospell (from https://pypi.org/project/pospell). 2018-07-23 17:57:24 +02:00
.tx Transifex: Migrating from 3.6 to 3.7 too. 2018-06-30 12:00:20 +02:00
c-api Fixes Sphinx warnings 2018-07-17 00:02:01 +02:00
distributing Reviewing 3.7 fuzzy strings. (#203) 2018-07-21 10:59:44 +02:00
distutils Reviewing 3.7 fuzzy strings. (#203) 2018-07-21 10:59:44 +02:00
extending Reviewing 3.7 fuzzy strings. (#203) 2018-07-21 10:59:44 +02:00
faq Reviewing 3.7 fuzzy strings. (#203) 2018-07-21 10:59:44 +02:00
howto Relecture de Howto / Regex.po - début 2018-07-22 16:11:01 +02:00
install Update language team. 2018-07-04 11:14:25 +02:00
installing Dropping useless first author line. 2018-07-04 11:09:21 +02:00
library Reviewing 3.7 fuzzy strings. (#203) 2018-07-21 10:59:44 +02:00
reference Compound Statements et DataModel review due to 3.7 migration (#212) 2018-07-09 22:27:48 +02:00
tutorial Removing fuzzy from headers. 2018-07-04 11:16:54 +02:00
using Removing fuzzy from headers. 2018-07-04 11:16:54 +02:00
whatsnew Removing fuzzy from headers. 2018-07-04 11:16:54 +02:00
.gitattributes Document how I use .gitattributes to clean git diffs. 2017-08-01 13:36:07 +02:00
.gitignore Better documenting maintenance processes. 2017-08-11 23:33:03 +02:00
.travis.yml Simplifying install, cloning out of repo to avoid sphinx to search in cpython sources. 2018-07-23 11:58:48 +02:00
Makefile Make warnings errors, and fix warnings by patching Doc/Makefile and moving locales/ out of Doc/ 2018-07-23 14:55:58 +02:00
README.rst Bump progression. 2018-07-20 20:49:36 +02:00
TRANSLATORS Translate `modulefinder.po` (#233) 2018-07-12 22:29:40 +02:00
about.po First try playing with pospell (from https://pypi.org/project/pospell). 2018-07-23 17:57:24 +02:00
bugs.po First try playing with pospell (from https://pypi.org/project/pospell). 2018-07-23 17:57:24 +02:00
contents.po Removing fuzzy from headers. 2018-07-04 11:16:54 +02:00
copyright.po Update language team. 2018-07-04 11:14:25 +02:00
glossary.po Fixes Sphinx warnings 2018-07-17 00:02:01 +02:00
license.po Removing fuzzy from headers. 2018-07-04 11:16:54 +02:00
sphinx.po Update language team. 2018-07-04 11:14:25 +02:00

README.rst

French Translation of the Python Documentation

Translated: 29%

Documentation Contribution Agreement

NOTE REGARDING THE LICENSE FOR TRANSLATIONS: Python's documentation is maintained using a global network of volunteers. By posting this project on Transifex, Github, and other public places, and inviting you to participate, we are proposing an agreement that you will provide your improvements to Python's documentation or the translation of Python's documentation for the PSF's use under the CC0 license (available at https://creativecommons.org/publicdomain/zero/1.0/legalcode). In return, you may publicly claim credit for the portion of the translation you contributed and if your translation is accepted by the PSF, you may (but are not required to) submit a patch including an appropriate annotation in the Misc/ACKS or TRANSLATORS file. Although nothing in this Documentation Contribution Agreement obligates the PSF to incorporate your textual contribution, your participation in the Python community is welcomed and appreciated.

You signify acceptance of this agreement by submitting your work to the PSF for inclusion in the documentation.

Contributing to the Translation

How to Contribute

You can contribute using:

Contributing using Github

Prerequisites:

Let's start:

You'll need to fork the python-docs-fr clicking its Fork button. This creates a copy of the whole project on your github account: a place where you have the rights to do modifications.

Step by step:

# Git clone your github fork using ssh (replace JulienPalard):
git clone git@github.com:JulienPalard/python-docs-fr.git

# Go to the cloned directory:
cd python-docs-fr/

# Add the upstream (the public repository) using HTTPS (won't ask for password):
git remote add upstream https://github.com/python/python-docs-fr.git

Now you're ready to start a work session, each time you'll start a new task, start here:

# To work, we'll need a branch, based on an up-to-date (freshly fetched)
# upstream/3.7 branch, let's say we'll work on glossary so we name
# the branch "glossary":
git fetch upstream
git checkout -b glossary upstream/3.7

# You can now work on the file, typically using poedit,
poedit directory/file.po

# After writing your changes to disk, check for correctness:
make

# Sphinx will tell you if there is any syntax error in the files
# you modified. Note that in the French Translation, we try to keep Sphinx
# warnings to zero.

# you may want to check if there are semantic errors.
# Open the translated file in your browser to check how it renders.
# Don't forget to verify the typography. The French conventions are not
# the English ones, especially for punctuation.
# Also, Grammalecte, a browser plugin avaliable in your browser store,
# is your friend even if, because of the technical words that appear
# everywhere in the documentation, it points out many false positive.
exo-open ../cpython/Doc/build/html/directory/file.html

# When everything is clear (syntax errors from Sphinx, html rendering,
# semantics, typography),
# you can commit your work with a nice explicit message:
git commit -a -m "Working on glossary."

# Then push your modifications to your github clone,
# as they are ephemeral branches, let's not configure git to track them all,
# "origin HEAD" is a "special" syntax to say "Push on origin,
# on a branch with the same name as the local one",
# it's nice as it's exactly what we want:
git push origin HEAD

# Now you can open the pull request on github, just go to
# https://github.com/python/python-docs-fr/ and a nice "Compare & pull request"
# button should appear after a few seconds telling you can ask for a pull request.

# Now someone is reviewing your modifications, and you'll want to fix their
# findings, get back to your branch
# (in case you started something else on another branch):
git checkout glossary
# Fix the issues, then commit again:
git commit -a -m "glossary: small fixes."
git push origin HEAD

You may have noted that this looks like a triangle, with a missing segment:

  • You're fetching from upstream (public common repo on github)
  • You're pushing to origin (your clone on github)

So yes it's the work of someone to add the last segment, from your origin to the public upstream, to "close the loop", that's the role of the people who merges pull requests after proofreading them.

You may also have noted you never ever commit on a version branch (3.6, 3.7, ...), only pull from them, consider them read-only you'll avoid problems.

Before commiting, you should use grammalecte to check for your translations.

What to translate

You can start with easy tasks like reviewing fuzzy entries to help keeping the documentation up to date (find them using make fuzzy).

You can also proofread already translated entries, and finally translate untranslated ones (find them using make todo)..

  • Do not translate content of :ref:... and :term:...
  • Put english words, if you have to use them, in italics (surrounded by stars).
  • :: at the end of some paragraphs have to be translated to  : :: in French to place the space before the column.
  • If you translate a link title, please translate the link too (typically if it's Wikipedia and the article has a translation). If no translation of the target exists, do not translate the title.

Where to get help

The coordinator for this translation is mdk.

Feel free to ask your questions on the #python-fr channel on freenode (does not require registration) or the AFPy traductions mailing list.

Translation Resources

Glossary

For consistency in our translations, here are some propositions and reminders for frequent terms you'll have to translate, don't hesitate to open an issue if you disagree.

Term Proposed Translation
-like -compatible
abstract data type type abstrait
argument argument (Don't mix with parameter)
backslash antislash, backslash
bound lier
bug bogue, bug
built-in native
call stack pile d'appels
debugging débogage
double quote guillemet
e.g. e.g. (pour exempli gratia)
garbage collector ramasse-miettes
identifier identifiant
immutable immuable
interpreter interpréteur
library bibliothèque

list comprehension

liste en compréhension (liste en intension est valide, mais nous ne l'utilisons pas)

little-endian, big-endian

petit-boutiste, gros-boutiste

mutable muable
namespace namespace, espace de noms
parameter paramètre
prompt invite
raise lever
regular expression expression rationnelle, expression régulière

return

renvoie, donne (on évite "retourne" qui pourrait porter à confusion).

simple quote

guillemet simple, apostrophe (apostrophe is to glue, guillemet is to surround)

socket socket
statement instruction
thread fil d'exécution
underscore tiret bas, underscore

Project History

This project was started around 2012 by afpy members, in 2017 this project became the official french Python documentation translation thanks to PEP 545.

Simplify git diffs

Git diffs are often crowded with useless line number changes, like:

-#: ../Doc/library/signal.rst:406
+#: ../Doc/library/signal.rst:408

To tell git they are not usefull information, you can do the following after ensuring ~/.local/bin/ is in your PATH.

cat <<EOF > ~/.local/bin/podiff
#!/bin/sh
grep -v '^#:' "\$1"
EOF

chmod a+x ~/.local/bin/podiff

git config diff.podiff.textconv podiff

Maintenance

All those snippets are to run from the root of a python-docs-fr clone, and some expect to find an up-to-date CPython clone near to it, like:

.. code-block:: bash

~/ ├── python-docs-fr/ └── cpython/

To clone CPython you may use:

git clone --depth 1 --no-single-branch https://github.com/python/cpython.git

This avoids to download the whole history (not usefull to build documentation) but still fetches all branches.

Merge pot files from CPython

make merge

Find fuzzy strings

make fuzzy

Run a test build locally

make

Synchronize translation with Transifex

You'll need the transifex-client and poindent from Pypi.

You'll need to configure tx via tx init if not already done.

You should work on a separate transifex branch.

tx pull
poindent --modified
git commit -m "tx pull"
git checkout 3.6
git merge transifex -Xours
tx push -t