-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Crouton Command Cheat Sheet
munchkinhalfling edited this page Jan 21, 2020
·
20 revisions
- List targets (
-t
):crouton -t help
orcrouton -t list
- List supported Linux releases (
-r
):crouton -r list
- List all installed chroot names (
-a
):sudo edit-chroot -a
- List all installed chroot names with croutonversion (
-al
):sudo edit-chroot -al
- Check the crouton version (must run within a chroot):
croutonversion -u -c
(runcroutonversion -h
for more info) -
Update a chroot:
sudo crouton -u -n chrootname
. Note: this will update crouton and all installed targets. -
Update a chroot while adding new target(s):
sudo crouton -u -n chrootname -t targets_you_want_to_install_separated_by_commas
-
Backup a chroot to an SD Card:
sudo edit-chroot -f /media/removable/SD\ Card/ -b chrootname
(assumes the name of your SD Card is "SD Card") -
Backup a chroot to a USB drive:
sudo edit-chroot -f /media/removable/your_path_on_drive -b chrootname
-
Restore from a backup:
sudo edit-chroot -f /media/removable/your_path_on_drive -r chrootname
- Learn more about edit-chroot (i.e., man page):
edit-chroot
-
Delete a chroot:
sudo delete-chroot name_of_evilchroot
-
Rename a chroot:
sudo edit-chroot source -m destination
-
Switch between xorg and xiwi if both installed:
sudo startxfce4 -X xiwi
orsudo startxfce4 -X xorg
(replacestartxfce4
with your interface shortcut from the setup). -
Mount a chroot and enter the 'shell':
sudo enter-chroot -n chrootname
(runmount-chroot
for more info) -
Unmount a chroot:
sudo unmount-chroot chrootname
(rununmount-chroot
for more info). Using the -f switch can be helpful for freeing up orphaned processes from 'xiwi -T' apps that mounted in the background using the 'enter-chroot -b' background exec. -
Launch a single app in a Window in the background1:
sudo startxiwi -b -n chrootname app_name
(e.g.,xterm
) -
Launch a single app in a Tab:
sudo startxiwi -n chrootname -T app_name
(e.g.,-T xterm
)
Notes
- Think of some notations as variables in an equation. For example, substitute the name of your chroot for
chrootname
orname_of_evilchroot
. - Similarly,
source
is the name of the source chroot that you want to change, anddestination
is the new name of a chroot. - Use the
-f
switch to define the path. The user download directory is~/Downloads
and an external drive begins/media/removable/
. To check your path, usecd
andls
from within the shell. For example, entercd /media/removable/
and thenls
to check. - To run a chroot in a window you need the browser integration extension and you must install
-t xiwi
. To run the old fashioned way, you need-t xorg
. To switch between the two, see above. - Once you mount a chroot (see above) you can update and install packages. Stay away from the Ubuntu Software manager, and use the command line. See Ubuntu's AptGet/Howto.
1: When using the 'xiwi-app', if the Linux app that is being launched forks (to the background) - use the 'xiwi' -f
option to keep xiwi running until all windows are closed. For more info, please see this page in the Wiki.
Remember that you can copy and paste in the shell with Ctrl+Shift+C and Ctrl+Shift+V. For a bonus, try the up arrow key, the next time you're in the shell.