Skip to content

zaderrr/Install-opt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 

Repository files navigation

install-opt

A simple Linux CLI tool to install portable applications into /opt and automatically create a .desktop launcher.

Supports:

  • Extracted application folders (tar.gz / zip releases)
  • Standalone .AppImage files

After installation, the original source is automatically cleaned up when located in common download/temp directories.

*All from chatjippity - will probably break your installs (probably) *


✨ Features

  • Installs applications into /opt/{program}

  • Creates a per-user launcher in:

    ~/.local/share/applications

  • Supports extracted folder installs

  • Supports .AppImage installs

  • Automatic safe cleanup of source files

  • Optional StartupWMClass

  • Optional custom icon support

  • Safe replacement with --force


πŸ“¦ Why This Exists

Many Linux applications are distributed as:

  • Portable tarballs
  • Zip archives
  • AppImages

The manual workflow usually looks like:

  1. Extract archive (if needed)
  2. Move to /opt
  3. Make executable
  4. Create .desktop file
  5. Clean up download

install-opt automates that process in one command.


πŸš€ Installation

Make the script executable:

chmod +x install-opt

πŸ›  Usage

Folder mode

install-opt \
  --name <Name> \
  --src <extracted-folder> \
  --exec <relative-path-to-executable> \
  --icon <relative-path-to-icon> \
  --categories <desktop-categories> \
  --comment <description> \
  --wmclass <startupWMclass> \
  --force
Argument Default Description
--icon (none) Relative path to an icon file (png/svg) inside the directory.
--categories Utility; Desktop entry categories (e.g. Development;IDE;).
--comment Installed app Description shown in application menu.
--terminal false Whether the app should launch inside a terminal.
--wmclass (none) StartupWMClass value for proper dock/taskbar grouping.
--force disabled Replace existing installation in /opt/{program} if it exists.

AppImage mode

Use this mode for standalone .AppImage files.

Syntax

install-opt \
  --name <program> \
  --src <file.AppImage> \
  --appimage \
  [options]

Example

install-opt \
  --name obsidian \
  --src ~/Downloads/Obsidian-1.5.3.AppImage \
  --categories "Office;Utility;" \
  --comment "Obsidian Markdown Editor" \
  --force

The AppImage will be installed as:

/opt/{program}/{program}.AppImage

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages