Systèmes d'exploitation
Un article de Haypo.
(Différences entre les versions)
| Version du 12 janvier 2010 à 14:11 (modifier) Haypo (Discuter | Contributions) ← Différence précédente |
Version du 12 janvier 2010 à 14:12 (modifier) (défaire) Haypo (Discuter | Contributions) Différence suivante → |
||
| Ligne 9 : | Ligne 9 : | ||
| * [http://docs.python.org/library/platform.html#platform.system platform.system()] : 'Windows', 'Linux', 'FreeBSD' | * [http://docs.python.org/library/platform.html#platform.system platform.system()] : 'Windows', 'Linux', 'FreeBSD' | ||
| * [http://docs.python.org/library/sys.html#sys.platform sys.platform] : 'win32', 'cygwin', 'darwin', 'os2', 'os2emx', 'riscos', 'atheos' | * [http://docs.python.org/library/sys.html#sys.platform sys.platform] : 'win32', 'cygwin', 'darwin', 'os2', 'os2emx', 'riscos', 'atheos' | ||
| - | * [http://docs.python.org/library/sys.html#sys.getwindowsversion sys.getwindowsversion()] | + | * Windows : |
| + | ** [http://docs.python.org/library/sys.html#sys.getwindowsversion sys.getwindowsversion()] | ||
| + | ** [http://docs.python.org/library/sys.html#sys.winver sys.winver] | ||
Version du 12 janvier 2010 à 14:12
Catégorie:Programmation
Retour aux articles de programmation
Identifier un système d'exploitation
uname() : appel système (sous Linux en tout cas).
En Python :
- platform.system() : 'Windows', 'Linux', 'FreeBSD'
- sys.platform : 'win32', 'cygwin', 'darwin', 'os2', 'os2emx', 'riscos', 'atheos'
- Windows :

