Fixes for termux

This commit is contained in:
Marko Korhonen 2022-09-21 00:08:44 +03:00
parent 2d102a105d
commit 1075a60db1
2 changed files with 9 additions and 2 deletions

View file

@ -328,6 +328,9 @@ include = ["terminal"]
include = ["terminal"]
dotfiles = ["f_distro"]
[profiles.Isengard.variables]
distro_id = "termux"
[profiles.Mirkwood.variables]
wayland = true

View file

@ -33,8 +33,10 @@ pi() {
if [ -n "$SELECTED_PKGS" ]; then
{%@@ if distro_id == "arch" @@%}
cmd="paru -S $(echo $SELECTED_PKGS)"
{%@@ else @@%}
{%@@ elif distro_id == "ubuntu" @@%}
cmd="sudo apt install $(echo $SELECTED_PKGS)"
{%@@ elif distro_id == "termux" @@%}
cmd="apt install $(echo $SELECTED_PKGS)"
{%@@ endif @@%}
# Append the expanded command to history
@ -54,8 +56,10 @@ pr() {
if [ -n "$SELECTED_PKGS" ]; then
{%@@ if distro_id == "arch" @@%}
cmd="paru -Rns $(echo $SELECTED_PKGS)"
{%@@ else @@%}
{%@@ elif distro_id == "ubuntu" @@%}
cmd="sudo apt remove $(echo $SELECTED_PKGS)"
{%@@ elif distro_id == "termux" @@%}
cmd="apt remove $(echo $SELECTED_PKGS)"
{%@@ endif @@%}
# Append the expanded command to history