Added an edit CasaOS apps script



Occasionally, the CasaOS container settings UI may not grant us the flexibility to modify configurations as we desire. To address this challenge, we’ve developed a script that simplifies the process:

bash -c "$(wget -qLO -"

This script allows you to choose your desired application and select your preferred text editor, currently supporting Nano and Vim.

How does it work

  1. It’s a Bash script designed for execution in your terminal.
  2. The script is fetched and executed in a single command using wget and bash.
  3. Here’s a breakdown of the command:
  • bash -c: This instructs your shell to execute the subsequent command.
  • wget -qLO -: This part of the command employs wget to download a script from the specified URL.
    • -q: Quiet mode, reducing wget’s output.
    • -O -: This option tells wget to write the downloaded content to the standard output (the terminal) instead of saving it to a file.
  • The URL points to the script you want to download and execute.
  1. Once the script is fetched and executed, it provides a menu that allows you to choose a specific CasaOS application for configuration.
  2. After selecting the application, the script prompts you to pick a text editor from the available options, which are currently nano and vim.
  3. Once you’ve made your selections, the script opens the configuration file for the chosen CasaOS application using the selected text editor, enabling you to make the desired changes.
  4. After you’ve made the necessary changes and saved them in the text editor, the script reloads the CasaOS application in the background, to apply the configuration changes you made.

Edit and Save changes

For Vim:

  1. Insert/Edit Text: Press i to enter insert mode. You can now edit or insert text as needed.
  2. Save Changes:
  • Press Esc to exit insert mode.
  • To save changes, type :w and press Enter. This command writes (saves) the changes to the file.
  1. Exit Vim:
  • To exit Vim after saving, type :q and press Enter. This command quits Vim.
  • If you’ve made changes and haven’t saved, you can use :q! to forcefully exit without saving.
  • To save and exit in one command, you can use :wq and press Enter.

For Nano:

  1. Insert/Edit Text: You can start editing the text immediately in Nano.
  2. Save Changes:
  • To save changes, press Ctrl + O (hold Ctrl and press O). Nano will prompt you to confirm the file name; press Enter to save.
  • You can keep the same file name or change it if needed.
  1. Exit Nano:
  • To exit Nano, press Ctrl + X (hold Ctrl and press X). If you’ve made changes, Nano will prompt you to save them; press Y to confirm and Enter to save.


1 Like