Tutorial Ubuntu : Différence entre versions

De MicMac
Aller à : navigation, rechercher
Ligne 2 : Ligne 2 :
  
 
===sudo===
 
===sudo===
* Signification : super user
+
* Meaning : super user
* Permet d'exécuter des commandes en tant qu'un autre utilisateur, donc avec d'autres privilèges que les siens.
+
* Useful when you want to execute command with all the right.
* '''Exemples d'utilisation :'''
+
* '''Example :'''
** $ sudo reboot : Lance la commande reboot avec les droits de l'utilisateur root  
+
** $ sudo reboot : Launch the reboot command with the root user right.
  
 
===apt-get===
 
===apt-get===
* Signinfication : avanced package tool -get
+
* Meaning : avanced package tool -get
* Permet l’installation et le retrait de packages en tenant compte des dépendances ainsi que le téléchargement des packages s’ils sont sur une source réseau.
+
* Allows to install and remove package.
  
 
===ls===
 
===ls===
* Signification : list segment
+
* Meaning : list segment
* Permet de lister un répertoire
+
* Allows to list directory
* '''Exemples d'utilisation :'''
+
* '''Examples :'''
** ls -a : affiche tous les fichiers et répertoires cachés du répertoire courant.
+
** ls -a : display all the hidden folders and directories from the current folder.
** ls /etc/ : affiche le contenu du répertoire /etc/
+
** ls /etc/ : Display all the contents from the folder.
  
 
===cd===  
 
===cd===  
* Signification : change directory
+
* Meaning : change directory
* Permet de se déplacer dans les répertoires
+
* Allows to move into the different folders.
* '''Exemples d'utilisation :'''
+
* '''Examples :'''
** cd : permet de revenir au répertoire /home/utilisateur (identique à cd -)
+
** cd : Allows to go to the /home/user directory.
** cd .. : permet de revenir au répertoire précèdent
+
** cd .. : Allows to go back to the previous directory.
* '''Exemples d'utilisation :'''
+
* '''Examples :'''
** apt-get update : Met à jour la liste de packages.
+
** apt-get update : Update packages list.
** apt-get upgrade : Met à jour tous les packages installés.
+
** apt-get upgrade : Upgrade every packages already installed.
** apt-get install package1 package2 : Installe package1 et package2.
+
** apt-get install package1 package2 : Install package1 and package2.
** apt-get –purge remove package3 : Supprime package3 ainsi que tous les fichiers de configuration.
+
** apt-get –purge remove package3 : Remove package3 and every configuration files.
** cd / : permet de remonter au répertoire parent
+
** cd / : Allows to switch back to the previous folder.
  
 
===mv===
 
===mv===
* Signification : move
+
* Meaning : move
* Permet de copier des fichiers ou des répertoires
+
* Allows to copy files and directories.
*'''Exemples d'utilisation :'''
+
*'''Examples :'''
** mv monFichier unRep/ : Déplace monFichier dans le répertoire unRep
+
** mv myFile OneRep/ : Move MyFile into the OneRep directory.
** mv unRep/monFichier : Déplace le fichier monFichier du répertoire unRep là où on se trouve
+
** mv OneRep/myFile : Move MyFile from the OneDir directory to the directory we currently are.
** mv unRep monRep : Renomme unRep en monRep
+
** mv OneRep MyDir : Rename OneRep into MyRep.
  
 
===cp===
 
===cp===
* Signification : copy
+
* Meaning : copy
* Permet de copier des fichiers ou des répertoires
+
* Allows to copy files or directories.
* '''Exemples d'utilisation :'''  
+
* '''Examples :'''  
** cp monFichier sousrep/ : Copie monFichier dans sousrep
+
** cp myFile subdir/ : Copy MyFile into subdir
** cp -r monRep/ ailleurs/ : Copie le répertoire monRep vers ailleurs en créant le répertoire s'il n'existe pas.
+
** cp -r monRep/ somewhereelse/ : Copy MyDir directory somewhere else while creating the folder if it doesn't exist yet.
  
 
===rm===  
 
===rm===  
* Signification : remove
+
* Meaning : remove
* Permet d'effacer des fichiers
+
* Allows to erase files.
* '''Exemples d'utilisation :''' <br>
+
* '''Examples :'''  
** rm CeFichier : Efface le fichier CeFichier
+
** rm ThisFile : Erase the file ThisFile
** rm -rf /tmp/LeRep : Efface le répertoire /tmp/LeRep ainsi que tous ses fichiers sans demander de confirmation.
+
** rm -rf /tmp/ThisDir : Erase the /tmp/ThisDir directory and every folders in it.
  
 
===mkdir===
 
===mkdir===
* Signification : make directory
+
* Meaning : make directory
* Crée un répertoire vide
+
* Create an empty folder.
* '''Exemples d'utilisation :''' <br>
+
* '''Examples :'''  
** mkdir photos : Crée le répertoire photos
+
** mkdir photos : Create the photos folder.
** mkdir -p photos/2005/noel : Crée le répertoire noel et s'ils n'existent pas les répertoires 2005 et photos
+
** mkdir -p photos/2005/christmas : Create the christmas directory and if doesn't exist yet, the 2005 and photos directories.
  
 
===rmdir===
 
===rmdir===
* Signification : remove directory
+
* Meaning : remove directory
* Supprime un répertoire vide
+
* Delete an empty directory.
* ''' Exemple d'utilisation :''' <br>
+
* ''' Example :''' <br>
** rmdir LeRep : Supprime le répertoire LeRep
+
** rmdir ThisDir : Delete ThisDir folder.
  
 
===find===
 
===find===
* Signification : rechercher
+
* Meaning : Find
* Permet de chercher des fichiers et éventuellement d'exécuter des commandes sur ceux-ci ; la recherche est récursive c'est-à-dire qu'elle concerne le répertoire de départ et toute sa descendance (sous-répertoires ainsi que toute leur descendance...)
+
* Allows to find files and eventually to execute command on these files. Find command affect the origin directory but also the whole subdirectories in it.
* ''' Exemples d'utilisations :''' <br>
+
* ''' Examples :'''  
** Se placer dans le répertoire à partir duquel la recherche récursive doit être effectuée et faites :  
+
** Go into the directory where you want to execute the find command :  
 
** find monfichier* : Recherche un fichier commençant par "monfichier"
 
** find monfichier* : Recherche un fichier commençant par "monfichier"
 
** find *monfichier*.ogg : Recherche un fichier contenant "monfichier" et ayant pour extension ".ogg"
 
** find *monfichier*.ogg : Recherche un fichier contenant "monfichier" et ayant pour extension ".ogg"
  
==Raccourcis clavier==
+
==Keyboard shortcuts==
* Stoppe les programmes : Alt+Syst+E
+
* Stop all the programs : Alt+Syst+E
* Tue tous les programmes : Alt+Syst+I
+
* Kill all the programs : Alt+Syst+I
* Redémarrage brutal : Alt+Syst+B
+
* Brutal reboot : Alt+Syst+B
* Arrêt brutal : Alt+Syst+O
+
* Brutal shutdown : Alt+Syst+O
* Faire apparaitre le menu de fenêtre : Alt+Espace
+
* Make appear the windows display : Alt+Espace
* Menu "Applications" : Alt+F1
+
* "Applications" display : Alt+F1
* Lancer une commande : Alt+F2
+
* Launch command : Alt+F2
* Fermer l'application ouverte : Alt+F4
+
* Shut the current opened application : Alt+F4
* Basculer d'une fenêtre à l'autre : Alt+Tab
+
* Switch to one window to another : Alt+Tab
* Remonter d’un niveau de répertoire : backspace
+
* Go back from one directory : backspace
* Revenir au répertoire utilisateur : Alt+Orig
+
* Go back to the users directory : Alt+Orig

Version du 1 février 2016 à 11:32

Commandes Ubuntu à connaître

sudo

  • Meaning : super user
  • Useful when you want to execute command with all the right.
  • Example :
    • $ sudo reboot : Launch the reboot command with the root user right.

apt-get

  • Meaning : avanced package tool -get
  • Allows to install and remove package.

ls

  • Meaning : list segment
  • Allows to list directory
  • Examples :
    • ls -a : display all the hidden folders and directories from the current folder.
    • ls /etc/ : Display all the contents from the folder.

cd

  • Meaning : change directory
  • Allows to move into the different folders.
  • Examples :
    • cd : Allows to go to the /home/user directory.
    • cd .. : Allows to go back to the previous directory.
  • Examples :
    • apt-get update : Update packages list.
    • apt-get upgrade : Upgrade every packages already installed.
    • apt-get install package1 package2 : Install package1 and package2.
    • apt-get –purge remove package3 : Remove package3 and every configuration files.
    • cd / : Allows to switch back to the previous folder.

mv

  • Meaning : move
  • Allows to copy files and directories.
  • Examples :
    • mv myFile OneRep/ : Move MyFile into the OneRep directory.
    • mv OneRep/myFile : Move MyFile from the OneDir directory to the directory we currently are.
    • mv OneRep MyDir : Rename OneRep into MyRep.

cp

  • Meaning : copy
  • Allows to copy files or directories.
  • Examples :
    • cp myFile subdir/ : Copy MyFile into subdir
    • cp -r monRep/ somewhereelse/ : Copy MyDir directory somewhere else while creating the folder if it doesn't exist yet.

rm

  • Meaning : remove
  • Allows to erase files.
  • Examples :
    • rm ThisFile : Erase the file ThisFile
    • rm -rf /tmp/ThisDir : Erase the /tmp/ThisDir directory and every folders in it.

mkdir

  • Meaning : make directory
  • Create an empty folder.
  • Examples :
    • mkdir photos : Create the photos folder.
    • mkdir -p photos/2005/christmas : Create the christmas directory and if doesn't exist yet, the 2005 and photos directories.

rmdir

  • Meaning : remove directory
  • Delete an empty directory.
  • Example :
    • rmdir ThisDir : Delete ThisDir folder.

find

  • Meaning : Find
  • Allows to find files and eventually to execute command on these files. Find command affect the origin directory but also the whole subdirectories in it.
  • Examples :
    • Go into the directory where you want to execute the find command :
    • find monfichier* : Recherche un fichier commençant par "monfichier"
    • find *monfichier*.ogg : Recherche un fichier contenant "monfichier" et ayant pour extension ".ogg"

Keyboard shortcuts

  • Stop all the programs : Alt+Syst+E
  • Kill all the programs : Alt+Syst+I
  • Brutal reboot : Alt+Syst+B
  • Brutal shutdown : Alt+Syst+O
  • Make appear the windows display : Alt+Espace
  • "Applications" display : Alt+F1
  • Launch command : Alt+F2
  • Shut the current opened application : Alt+F4
  • Switch to one window to another : Alt+Tab
  • Go back from one directory : backspace
  • Go back to the users directory : Alt+Orig