Systèmes d'exploitation
Un article de Haypo.
(Différences entre les versions)
												
			
			| Version du 12 janvier 2010 à 14:10 (modifier) Haypo (Discuter | Contributions) m (Nouvelle page : Catégorie:Programmation {{Retour|Programmation|Retour aux articles de programmation}} == Identifier un système d'exploitation == uname() : appel système (sous Linux en tout ...) ← Différence précédente | Version du 12 janvier 2010 à 14:11 (modifier) (défaire) Haypo (Discuter | Contributions) Différence suivante → | ||
| Ligne 8 : | Ligne 8 : | ||
| En Python : | En Python : | ||
| * [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' | |
| - | * sys.platform | + | |
| - | + | ||
| - | + | ||
| * [http://docs.python.org/library/sys.html#sys.getwindowsversion sys.getwindowsversion()] | * [http://docs.python.org/library/sys.html#sys.getwindowsversion sys.getwindowsversion()] | ||
Version du 12 janvier 2010 à 14:11
Catégorie:Programmation
 Retour aux articles de 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'
- sys.getwindowsversion()

