updated build files
|
@ -6,7 +6,7 @@ GenericName=System Monitor
|
|||
GenericName[it]=Monitor di sistema
|
||||
Comment=Resource monitor that shows usage and stats for processor, memory, disks, network and processes
|
||||
Comment[it]=Monitoraggio delle risorse: mostra utilizzo e statistiche per CPU, dischi, rete e processi
|
||||
Icon=btopep
|
||||
Icon=/usr/share/pixmaps/btopep.png
|
||||
Exec=xfce4-terminal -H -e "sh -c 'btop'"
|
||||
Terminal=true
|
||||
Categories=XFCE;GTK;Settings;X-XFCE-SettingsDialog;
|
||||
|
|
|
@ -1,164 +0,0 @@
|
|||
[Desktop Entry]
|
||||
Name=GDebi Package Installer
|
||||
Name[ar]=مثبت الحزم GDebi
|
||||
Name[ast]=Instalador de Paquetes GDebi
|
||||
Name[bg]=Инсталатор на пакет
|
||||
Name[bn]=প্যাকেজ ইনস্টলার
|
||||
Name[bs]=GDebi Paketni Instaler
|
||||
Name[ca]=Instal·lador de paquets GDebi
|
||||
Name[ca@valencia]=Instal·lador de paquets GDebi
|
||||
Name[cs]=Instalátor balíků GDebi
|
||||
Name[da]=GDebi pakkeinstalleringsprogram
|
||||
Name[de]=GDebi-Paket-Installationsprogramm
|
||||
Name[el]=Εγκατάσταση πακέτων GDebi
|
||||
Name[en_AU]=GDebi Package Installer
|
||||
Name[en_CA]=GDebi Package Installer
|
||||
Name[en_GB]=GDebi Package Installer
|
||||
Name[eo]=Instalilo de GDebi-pakaĵoj
|
||||
Name[es]=Instalador de paquetes GDebi
|
||||
Name[et]=GDebi Paketipaigaldus
|
||||
Name[eu]=GDebi pakete-instalatzailea
|
||||
Name[fi]=GDebi-paketinasentaja
|
||||
Name[fo]=GDebi Pakka innleggjari
|
||||
Name[fr]=Installateur de paquets GDebi
|
||||
Name[gl]=Instalador de paquetes GDebi
|
||||
Name[he]=מתקין החבילות GDebi
|
||||
Name[hu]=GDebi csomagtelepítő
|
||||
Name[id]=Pemasang Paket GDebi
|
||||
Name[it]=Installatore pacchetto GDebi
|
||||
Name[ja]=GDebi パッケージインストーラー
|
||||
Name[ko]=GDebi 패키지 설치 프로그램
|
||||
Name[lt]=„GDebi“ paketų diegyklė
|
||||
Name[ms]=Pemasang Pakej GDebi
|
||||
Name[nb]=GDebi pakkeinstallerer
|
||||
Name[nl]=GDebi pakketinstalleerder
|
||||
Name[oc]=Installador de paquets GDebi
|
||||
Name[pl]=Instalator pakietów GDebi
|
||||
Name[pt]=Instalador de Pacotes
|
||||
Name[pt_BR]=Instalador de pacotes GDebi
|
||||
Name[ro]=GDebi instalator de pachete
|
||||
Name[ru]=Программа установки пакетов GDebi
|
||||
Name[sk]=Inštalátor balíkov GDebi
|
||||
Name[sl]=Namestilnik paketov GDebi
|
||||
Name[sr]=ГДеби — Инсталер пакета
|
||||
Name[sv]=Paketinstalleraren GDebi
|
||||
Name[te]=GDebi ప్యాకేజీ స్థాపకం
|
||||
Name[tr]=GDebi Paket Kurucu
|
||||
Name[uk]=Встановлювач пакунків GDebi
|
||||
Name[ur]=جی ڈیبی پیکج انسٹالر
|
||||
Name[zh_CN]=GDebi 软件包安装程序
|
||||
Name[zh_HK]=GDebi 套件安裝程式
|
||||
Name[zh_TW]=GDebi 套件安裝程式
|
||||
GenericName=Package Installer
|
||||
GenericName[ar]=مثبت الحزم
|
||||
GenericName[ast]=Instalador de paquetes
|
||||
GenericName[bg]=Инсталатор на пакети
|
||||
GenericName[bn]=প্যাকেজ ইনস্টলার
|
||||
GenericName[bs]=Paketni instaler
|
||||
GenericName[ca]=Instal·lador de paquets
|
||||
GenericName[ca@valencia]=Instal·lador de paquets
|
||||
GenericName[cs]=Instalátor balíků
|
||||
GenericName[da]=Pakkeinstalleringsprogram
|
||||
GenericName[de]=Paket-Installationsprogramm
|
||||
GenericName[el]=Εγκατάσταση πακέτων
|
||||
GenericName[en_AU]=Package Installer
|
||||
GenericName[en_CA]=Package Installer
|
||||
GenericName[en_GB]=Package Installer
|
||||
GenericName[eo]=Instalilo de pakaĵoj
|
||||
GenericName[es]=Instalador de paquetes
|
||||
GenericName[et]=Paketti paigaldus
|
||||
GenericName[eu]=Pakete-instalatzailea
|
||||
GenericName[fi]=Paketinasentaja
|
||||
GenericName[fo]=Pakkainnleggjari
|
||||
GenericName[fr]=Installateur de paquets
|
||||
GenericName[gl]=Instalador de paquetes
|
||||
GenericName[he]=מתקין החבילות
|
||||
GenericName[hr]=Paketni instaler
|
||||
GenericName[hu]=Csomagtelepítő
|
||||
GenericName[id]=Pemasang Paket
|
||||
GenericName[it]=Installatore pacchetto
|
||||
GenericName[ja]=パッケージインストーラー
|
||||
GenericName[ko]=패키지 설치 프로그램
|
||||
GenericName[ku]=Sazgera Paketan
|
||||
GenericName[lt]=Paketų diegyklė
|
||||
GenericName[ms]=Pemasang Pakej
|
||||
GenericName[nb]=Pakkeinstallerer
|
||||
GenericName[nl]=Pakketinstalleerder
|
||||
GenericName[oc]=Installador de paquets
|
||||
GenericName[pl]=Instalator pakietów
|
||||
GenericName[pt]=Instalador de Pacotes
|
||||
GenericName[pt_BR]=Instalador de Pacotes
|
||||
GenericName[ro]=Instalator pachete
|
||||
GenericName[ru]=Программа установки пакетов
|
||||
GenericName[sk]=Inštalátor balíkov
|
||||
GenericName[sl]=Namestilnik paketov
|
||||
GenericName[sr]=Инсталер пакета
|
||||
GenericName[sv]=Paketinstallerare
|
||||
GenericName[te]=ప్యాకేజీ స్థాపకం
|
||||
GenericName[tr]=Paket Kurucu
|
||||
GenericName[uk]=Встановлювач пакунків
|
||||
GenericName[ur]=پیکج تنصیب کار
|
||||
GenericName[zh_CN]=软件包安装程序
|
||||
GenericName[zh_HK]=套件安裝程式
|
||||
GenericName[zh_TW]=套件安裝程式
|
||||
Comment=Install and view software packages
|
||||
Comment[ar]=تثبيت و عرض حزم البرامج
|
||||
Comment[ast]=Instalar y ver paquetes de software
|
||||
Comment[bg]=Инсталиране и преглед на пакети
|
||||
Comment[bn]=সফটওয়্যার প্যাকেজ ইনস্টল করুন এবং দেখুন
|
||||
Comment[bs]=Instaliraj i vidi softverski paket
|
||||
Comment[ca]=Instal·la i visualitza paquets de programari
|
||||
Comment[ca@valencia]=Instal·la i visualitza paquets de programari
|
||||
Comment[cs]=Instalovat a prohlížet balíky
|
||||
Comment[da]=Installer og vis softwarepakker
|
||||
Comment[de]=Software-Pakete installieren und betrachten
|
||||
Comment[el]=Εγκαταστήστε και εμφανίστε πακέτα λογισμικού
|
||||
Comment[en_AU]=Install and view software packages
|
||||
Comment[en_CA]=Install and view software packages
|
||||
Comment[en_GB]=Install and view software packages
|
||||
Comment[eo]=Instali kaj vidi pakaĵojn de programaroj
|
||||
Comment[es]=Instala y muestra paquetes de software
|
||||
Comment[eu]=Instalatu eta ikusi software paketeak
|
||||
Comment[fi]=Asenna ja tarkastele ohjelmapaketteja
|
||||
Comment[fo]=Legg inn og vís ritbúnaðarpakkar
|
||||
Comment[fr]=Installer et lister les paquets logiciels
|
||||
Comment[gl]=Instalar e ver paquetes de software
|
||||
Comment[he]=התקנה וצפייה של חבילות תכנה
|
||||
Comment[hr]=Instaliraj i pregledaj pakete
|
||||
Comment[hu]=Szoftvercsomagok telepítése és megjelenítése
|
||||
Comment[id]=Pasang dan tinjau paket-paket piranti lunak
|
||||
Comment[it]=Installa e visualizza pacchetti software
|
||||
Comment[ja]=ソフトウェアパッケージのインストールと表示を行います
|
||||
Comment[ko]=소프트웨어 패키지를 설치하고 봅니다
|
||||
Comment[ku]=Paketên nivîsbariyê saz bike û lê binêre
|
||||
Comment[lt]=Įdiegti ir peržiūrėti programinės įrangos paketus
|
||||
Comment[ms]=Pasang dan papar pakej perisian
|
||||
Comment[nb]=Installer og vis programvarepakker
|
||||
Comment[nl]=Programmapakketten installeren en bekijken
|
||||
Comment[oc]=Installar e far la lista dels paquets logicials
|
||||
Comment[pl]=Instaluje i wyświetla informacje o pakietach oprogramowania
|
||||
Comment[pt]=Instalar e ver pacotes de software
|
||||
Comment[pt_BR]=Instalar e visualizar pacotes de programa
|
||||
Comment[ro]=Instalare şi vizualizare pachete software
|
||||
Comment[ru]=Программа установки и просмотра пакетов программ
|
||||
Comment[sk]=Inštalácia a zobrazenie balíkov softvéru
|
||||
Comment[sl]=Nameščanje in ogled paketov programske opreme
|
||||
Comment[sr]=Инсталирајте и погледајте софтверске пакете
|
||||
Comment[sv]=Installera och visa programpaket
|
||||
Comment[te]=సాఫ్ట్వేర్ ప్యాకేజీలను స్థాపించు మరియు చూడు
|
||||
Comment[tr]=Yazılım paketlerini kur ve izle
|
||||
Comment[uk]=Встановити та оглянути програмні пакунки
|
||||
Comment[ur]=اردو ترجمہ از محمد علی مکی
|
||||
Comment[zh_CN]=安装和查看软件包
|
||||
Comment[zh_HK]=安裝和檢視軟件套件
|
||||
Comment[zh_TW]=安裝和檢視軟體套件
|
||||
Exec=sh -c "gdebi-gtk %f"
|
||||
Icon=gnome-mime-application-x-deb
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=System;
|
||||
MimeType=application/vnd.debian.binary-package;
|
||||
NotShowIn=KDE;
|
||||
X-Ubuntu-Gettext-Domain=gdebi
|
||||
StartupNotify=true
|
||||
Keywords=package;apt;dpkg;install
|
|
@ -5,6 +5,6 @@ Comment=A GUI for the xDaily Update Tool
|
|||
Categories=XFCE;GTK;Settings;X-XFCE-SettingsDialog;
|
||||
Type=Application
|
||||
Exec=xfce4-terminal -H -e "sh -c '/usr/local/bin/hblock'"
|
||||
Icon=hblock
|
||||
Icon=/usr/share/pixmaps/hblock.png
|
||||
Terminal=false
|
||||
NoDisplay=false
|
||||
|
|
|
@ -5,6 +5,6 @@ Comment=A GUI for the the suggested Tool
|
|||
Categories=XFCE;GTK;Settings;X-XFCE-SettingsDialog;
|
||||
Type=Application
|
||||
Exec=suggested
|
||||
Icon=suggested
|
||||
Icon=/usr/share/pixmaps/suggested.png
|
||||
Terminal=false
|
||||
NoDisplay=false
|
||||
|
|
|
@ -5,6 +5,6 @@ Comment=System information Tool
|
|||
Categories=XFCE;GTK;Settings;X-XFCE-SettingsDialog;
|
||||
Type=Application
|
||||
Exec=xfce4-terminal -H -e "sh -c 'pfetch'"
|
||||
Icon=system_info
|
||||
Icon=/usr/share/pixmaps/system_info.png
|
||||
Terminal=false
|
||||
NoDisplay=false
|
||||
|
|
|
@ -68,7 +68,7 @@ Comment[tr]=xDaily Güncelleme Aracı için bir GUI
|
|||
Categories=XFCE;GTK;Settings;X-XFCE-SettingsDialog;
|
||||
Type=Application
|
||||
Exec=xdaily-gui
|
||||
Icon=xd
|
||||
Icon=/usr/share/pixmaps/xd.png
|
||||
Terminal=false
|
||||
NoDisplay=false
|
||||
|
||||
|
|
|
@ -146,8 +146,6 @@ build_variant() {
|
|||
xmirror \
|
||||
chrony \
|
||||
void-repo-nonfree \
|
||||
void-repo-multilib \
|
||||
void-repo-multilib-nonfree \
|
||||
gvfs-afc \
|
||||
gvfs-mtp \
|
||||
gvfs-smb \
|
||||
|
@ -194,6 +192,7 @@ build_variant() {
|
|||
NetworkManager \
|
||||
network-manager-applet \
|
||||
luakit \
|
||||
peppermint-repo \
|
||||
$A11Y_PKGS \
|
||||
$GRUB_PKGS \
|
||||
$XORG_PKGS \
|
||||
|
|
|
@ -29,6 +29,15 @@ Terminal=false
|
|||
Categories=System;
|
||||
EOF
|
||||
|
||||
# Set permissions for the .desktop file
|
||||
# Set permissions for the .desktop file
|
||||
chmod +x "$desktop_dir/Calamares.desktop"
|
||||
|
||||
# Mark the desktop launcher as trusted (for GNOME/XFCE)
|
||||
gio set --type=string "$desktop_dir/Calamares.desktop" metadata::trusted true
|
||||
gio set --type=string "$desktop_dir/Calamares.desktop" metadata::xfce-exe-checksum \
|
||||
"$(sha256sum "$desktop_dir/Calamares.desktop" | cut -f1 -d' ')"
|
||||
|
||||
# Update the timestamp for the .desktop file
|
||||
touch "$desktop_dir/Calamares.desktop"
|
||||
fi
|
||||
|
||||
|
|
10
data/issue
|
@ -7,19 +7,13 @@ Two users are available to log in:
|
|||
- **root** : password **root**
|
||||
- **pep** : password **live**
|
||||
|
||||
The `anon` user has `sudo(8)` privileges to run any command without a password.
|
||||
The `pep` user has `sudo(8)` privileges to run any command without a password.
|
||||
|
||||
To start the installation, type:
|
||||
|
||||
# pep-installer
|
||||
|
||||
and follow the on-screen instructions. To install additional software, configure your network interface and use:
|
||||
To install additional software, configure your network interface and use:
|
||||
|
||||
- **xbps-install(1)** to install or update packages
|
||||
- **xbps-query(1)** to query package information
|
||||
|
||||
The PeppermintOS Handbook is also available offline in multiple formats and can be accessed with the `peppermint-docs(1)` utility.
|
||||
|
||||
Our thanks to the Void Linux team for providing this robust and versatile base, which has helped PeppermintOS reach new levels of efficiency and usability.
|
||||
|
||||
Thank you for choosing PeppermintOS!
|
||||
|
|
86
mklive.sh
|
@ -90,42 +90,11 @@ error_out() {
|
|||
exit "${1:-0}"
|
||||
}
|
||||
|
||||
usage() {
|
||||
cat <<-EOH
|
||||
Usage: $PROGNAME [options]
|
||||
|
||||
Generates a basic live ISO image of Void Linux. This ISO image can be written
|
||||
to a CD/DVD-ROM or any USB stick.
|
||||
|
||||
To generate a more complete live ISO image, use build-x86-images.sh.
|
||||
|
||||
OPTIONS
|
||||
-a <arch> Set XBPS_ARCH in the ISO image
|
||||
-b <system-pkg> Set an alternative base package (default: base-system)
|
||||
-r <repo> Use this XBPS repository. May be specified multiple times
|
||||
-c <cachedir> Use this XBPS cache directory (default: ./xbps-cachedir-<arch>)
|
||||
-k <keymap> Default keymap to use (default: us)
|
||||
-l <locale> Default locale to use (default: en_US.UTF-8)
|
||||
-i <lz4|gzip|bzip2|xz>
|
||||
Compression type for the initramfs image (default: xz)
|
||||
-s <gzip|lzo|xz> Compression type for the squashfs image (default: xz)
|
||||
-o <file> Output file name for the ISO image (default: automatic)
|
||||
-p "<pkg> ..." Install additional packages in the ISO image
|
||||
-g "<pkg> ..." Ignore packages when building the ISO image
|
||||
-I <includedir> Include directory structure under given path in the ROOTFS
|
||||
-S "<service> ..." Enable services in the ISO image
|
||||
-C "<arg> ..." Add additional kernel command line arguments
|
||||
-T <title> Modify the bootloader title (default: PeppermintOS)
|
||||
-v linux<version> Install a custom Linux version on ISO image (default: linux metapackage)
|
||||
-K Do not remove builddir
|
||||
-h Show this help and exit
|
||||
-V Show version and exit
|
||||
EOH
|
||||
}
|
||||
|
||||
copy_pep_os-release() {
|
||||
mkdir -p "$1"/etc
|
||||
cp os-release/* "$1"/etc
|
||||
mkdir -p "$1"/usr/lib
|
||||
cp os-release/* "$1"/usr/lib
|
||||
}
|
||||
|
||||
copy_pep_face() {
|
||||
|
@ -233,6 +202,11 @@ copy_pep_calamares_autostart() {
|
|||
cp calamares/autostart/* "$1"/etc/xdg/autostart
|
||||
}
|
||||
|
||||
copy_pep_plymouth() {
|
||||
mkdir -p "$1"/usr/share/plymouth/themes
|
||||
cp -r plymouth/themes/* "$1"/usr/share/plymouth/themes
|
||||
}
|
||||
|
||||
copy_void_keys() {
|
||||
mkdir -p "$1"/var/db/xbps/keys
|
||||
cp keys/*.plist "$1"/var/db/xbps/keys
|
||||
|
@ -316,26 +290,40 @@ generate_initramfs() {
|
|||
}
|
||||
|
||||
setup_plymouth() {
|
||||
# Define the Plymouth directory in rootfs
|
||||
local plymouth_dir="$1/usr/share/plymouth/themes"
|
||||
# Define the Plymouth configuration file location in rootfs
|
||||
local plymouth_config="$1/etc/plymouth/plymouthd.conf"
|
||||
|
||||
# Create the Plymouth themes directory if it doesn't exist
|
||||
mkdir -p "$plymouth_dir"
|
||||
|
||||
# Copy theme files to the Plymouth directory
|
||||
cp -r plymouth/theme/* "$plymouth_dir"
|
||||
# Create the Plymouth configuration directory if it doesn't exist
|
||||
mkdir -p "$(dirname "$plymouth_config")"
|
||||
|
||||
# Set Plymouth to use the copied default theme
|
||||
mkdir -p "$(dirname "$plymouth_config")"
|
||||
echo "Configuring Plymouth to use theme 'joy'..."
|
||||
echo "[Daemon]" > "$plymouth_config"
|
||||
echo "Theme=joy" >> "$plymouth_config"
|
||||
|
||||
# Ensure Plymouth will be started at boot
|
||||
echo "HOOK+=plymouth" >> "$1/etc/dracut.conf.d/plymouth.conf"
|
||||
echo "Adding Plymouth to dracut configuration..."
|
||||
|
||||
# Create the dracut configuration directory if it doesn't exist
|
||||
mkdir -p "$1/etc/dracut.conf.d"
|
||||
|
||||
# Correctly add the Plymouth module to dracut configuration
|
||||
echo 'add_dracutmodules+=" plymouth "' > "$1/etc/dracut.conf.d/plymouth.conf"
|
||||
|
||||
# Add the service to the initramfs so it starts with the system
|
||||
chroot "$1" dracut -f --add plymouth
|
||||
# Update the initramfs to include Plymouth
|
||||
echo "Updating initramfs to include Plymouth..."
|
||||
|
||||
# Ensure the kernel version is correctly specified
|
||||
local kernel_version
|
||||
kernel_version=$(ls "$1/lib/modules" | head -n 1)
|
||||
|
||||
if [ -z "$kernel_version" ]; then
|
||||
echo "Error: No kernel version found in $1/lib/modules."
|
||||
return 1
|
||||
fi
|
||||
|
||||
# Update initramfs using the specified kernel version
|
||||
chroot "$1" /usr/bin/dracut -f "/boot/initramfs-${kernel_version}.img" "${kernel_version}" --add plymouth
|
||||
|
||||
info_msg "Plymouth configured successfully with theme 'joy'."
|
||||
}
|
||||
|
@ -454,7 +442,7 @@ generate_grub_efi_boot() {
|
|||
rm -rf "$GRUB_EFI_TMPDIR"
|
||||
|
||||
# Include memtest86+ if needed
|
||||
cp -f "$PEPHOSTDIR"/boot/memtest.efi "$BOOT_DIR"
|
||||
cp -rf "$PEPHOSTDIR"/boot/memtest.efi "$BOOT_DIR"
|
||||
|
||||
echo "[*] EFI loaders with Secure Boot support generated successfully."
|
||||
}
|
||||
|
@ -524,9 +512,8 @@ while getopts "a:b:r:c:C:T:Kk:l:i:I:S:s:o:p:g:v:Vh" opt; do
|
|||
esac
|
||||
done
|
||||
shift $((OPTIND - 1))
|
||||
XBPS_REPOSITORY="$XBPS_REPOSITORY --repository=https://repo-default.voidlinux.org/current \
|
||||
--repository=https://repo-default.voidlinux.org/current/musl \
|
||||
--repository=https://www.repo.peppermintos.org/packages"
|
||||
XBPS_REPOSITORY="--repository=https://www.repo.peppermintos.org/packages $XBPS_REPOSITORY \
|
||||
--repository=https://repo-default.voidlinux.org/current/x86_64"
|
||||
|
||||
# Configure dracut to use overlayfs for the writable overlay.
|
||||
BOOT_CMDLINE="$BOOT_CMDLINE rd.live.overlay.overlayfs=1 "
|
||||
|
@ -613,6 +600,7 @@ copy_pep_lightdm "$ROOTFS"
|
|||
copy_pep_aliases "$ROOTFS"
|
||||
copy_pep_artwork "$ROOTFS"
|
||||
copy_pep_default_grub "$ROOTFS"
|
||||
copy_pep_plymouth "$ROOTFS"
|
||||
copy_pep_calamares_modules "$ROOTFS"
|
||||
copy_pep_calamares_branding "$ROOTFS"
|
||||
copy_pep_calamares_scripts "$ROOTFS"
|
||||
|
@ -668,7 +656,7 @@ print_step "Generating initramfs image ($INITRAMFS_COMPRESSION)..."
|
|||
generate_initramfs
|
||||
|
||||
print_step "Setup plymouth splash screen..."
|
||||
setup_plymouth
|
||||
setup_plymouth "$ROOTFS"
|
||||
|
||||
print_step "Generating isolinux support for PC-BIOS systems..."
|
||||
generate_isolinux_boot
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
NAME="Peppermint"
|
||||
ID=peppermint
|
||||
PRETTY_NAME="PeppermintOS"
|
||||
HOME_URL="https://peppermintos.com"
|
||||
SUPPORT_URL="https://sourceforge.net/p/peppermintos/pepos/"
|
||||
BUG_REPORT_URL="https://sourceforge.net/p/peppermintos/pepos/"
|
||||
DESTRIB_ID="peppermint"
|
||||
NAME="Peppermintos"
|
||||
ID="void"
|
||||
PRETTY_NAME="Peppermintos"
|
||||
HOME_URL="https://peppermintos.com/"
|
||||
DOCUMENTATION_URL="https://peppermint_os.codeberg.page/html/"
|
||||
LOGO="peppermint"
|
||||
ANSI_COLOR="0;38;2;71;128;97"
|
||||
DISTRIB_ID="peppermintos"
|
||||
|
|
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 12 KiB |
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 13 KiB |
Before Width: | Height: | Size: 269 B After Width: | Height: | Size: 269 B |
Before Width: | Height: | Size: 285 B After Width: | Height: | Size: 285 B |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 230 B After Width: | Height: | Size: 230 B |
Before Width: | Height: | Size: 229 B After Width: | Height: | Size: 229 B |
Before Width: | Height: | Size: 4.1 KiB After Width: | Height: | Size: 4.1 KiB |
Before Width: | Height: | Size: 269 B After Width: | Height: | Size: 269 B |
Before Width: | Height: | Size: 269 B After Width: | Height: | Size: 269 B |
|
@ -1,308 +0,0 @@
|
|||
"""
|
||||
* Author: "PeppermintOS Team(peppermintosteam@proton.me)
|
||||
*
|
||||
* License: SPDX-License-Identifier: GPL-3.0-or-later
|
||||
*
|
||||
* This is the hook module use dto run for the normal hooks,
|
||||
* this will run afte rthe ISO main build begins.
|
||||
"""
|
||||
import os
|
||||
import platform
|
||||
|
||||
|
||||
def apt_install_packages():
|
||||
"""
|
||||
The place where installing apt packaged is preffered during the
|
||||
hook run ran ther then the general build
|
||||
"""
|
||||
os.system('apt update')
|
||||
os.system('apt install --yes peppermint-wallpapers')
|
||||
|
||||
|
||||
def remove_packages_from_the_build():
|
||||
"""
|
||||
Uninstall unwanted packages from the build
|
||||
"""
|
||||
packages = [
|
||||
'konsole',
|
||||
'malcontent',
|
||||
'systemsettings',
|
||||
'nvidia*',
|
||||
'imagemagick-6.q16'
|
||||
]
|
||||
|
||||
for package in packages:
|
||||
os.system(f'apt --purge --yes autoremove {package}')
|
||||
|
||||
|
||||
def remove_desktop_files():
|
||||
"""
|
||||
Use this def to remove any .desktop files you donot need
|
||||
"""
|
||||
os.system('rm /usr/share/applications/btop.desktop')
|
||||
os.system('rm /usr/share/applications/librewolf.desktop')
|
||||
|
||||
|
||||
def install_librewolf_browser():
|
||||
"""
|
||||
Installs LibreWolf browser for Kumo by setting up sources and
|
||||
installing the package.
|
||||
"""
|
||||
path_to_file = '/opt/pepconf/'
|
||||
build_id_list = [
|
||||
path_to_file + 'deb.64xfc',
|
||||
path_to_file + 'dev.64xfc',
|
||||
path_to_file + 'deb.armxfc',
|
||||
path_to_file + 'dev.armxfc',
|
||||
path_to_file + 'deb.64gfb',
|
||||
path_to_file + 'dev.64gfb',
|
||||
path_to_file + 'deb.64opb',
|
||||
path_to_file + 'dev.64opb'
|
||||
]
|
||||
distro_cmd = (
|
||||
"distro=$(if echo ' una bookworm vanessa focal jammy bullseye vera uma ' | "
|
||||
"grep -q ' $(lsb_release -sc) '; then lsb_release -sc; else echo bookworm; fi); "
|
||||
"echo $distro"
|
||||
)
|
||||
for build_id in build_id_list:
|
||||
if os.path.exists(build_id):
|
||||
distro = os.popen(distro_cmd).read().strip()
|
||||
content = (
|
||||
f"Types: deb\n"
|
||||
f"URIs: https://deb.librewolf.net\n"
|
||||
f"Suites: {distro}\n"
|
||||
f"Components: main\n"
|
||||
f"Architectures: amd64\n"
|
||||
f"Signed-By: /usr/share/keyrings/librewolf.gpg\n"
|
||||
)
|
||||
|
||||
file_path = '/etc/apt/sources.list.d/librewolf.sources'
|
||||
os.system('apt update && '
|
||||
'apt install -y wget gnupg lsb-release apt-transport-https ca-certificates')
|
||||
os.system('wget -O- https://deb.librewolf.net/keyring.gpg | '
|
||||
'gpg --dearmor -o /usr/share/keyrings/librewolf.gpg')
|
||||
try:
|
||||
with open(file_path, 'w', encoding='utf-8') as f:
|
||||
f.write(content)
|
||||
os.chmod(file_path, 0o644)
|
||||
except PermissionError:
|
||||
print(f"Permission denied. Please run this script with "
|
||||
f"appropriate permissions to write to {file_path}.")
|
||||
return
|
||||
os.system('apt update')
|
||||
os.system('apt install librewolf -y')
|
||||
print("Browser installed!")
|
||||
else:
|
||||
print("No builds were met not installed")
|
||||
|
||||
|
||||
def setup_plymouth_theme_grub():
|
||||
"""
|
||||
Set the plymouth boot theme and desktop theme, as well as grub
|
||||
"""
|
||||
os.system('plymouth-set-default-theme -R joy')
|
||||
os.system('rm -f /etc/alternatives/desktop-theme')
|
||||
os.system('rm -f /etc/alternatives/desktop-grub')
|
||||
|
||||
theme_source = "/usr/share/desktop-base/joy-theme"
|
||||
theme_destination = "/etc/alternatives/desktop-theme"
|
||||
theme_command = f"ln -s {theme_source} {theme_destination}"
|
||||
os.system(theme_command)
|
||||
|
||||
grub_source = (
|
||||
"/usr/share/desktop-base/active-theme/grub/"
|
||||
"pep-grub-16x9.png"
|
||||
)
|
||||
grub_destination = "/etc/alternatives/desktop-grub"
|
||||
grub_command = f"ln -s {grub_source} {grub_destination}"
|
||||
os.system(grub_command)
|
||||
|
||||
|
||||
def hblock_setup():
|
||||
"""
|
||||
Install hblock to the system
|
||||
"""
|
||||
hb_url = "https://raw.githubusercontent.com/hectorm/hblock/master/hblock"
|
||||
hb_output = "/tmp/hblock"
|
||||
hb_command = f"curl {hb_url} --output {hb_output}"
|
||||
os.system(hb_command)
|
||||
file_path = "/tmp/hblock"
|
||||
expected_hash = "4031d86cd04fd7c6cb1b7e9acb1ffdbe9a3f84f693bfb287c68e1f1fa2c14c3b"
|
||||
sh_command = f'[ "$(sha256sum {file_path})" == "{expected_hash}" ]'
|
||||
os.system(sh_command)
|
||||
os.system('mv /tmp/hblock /usr/local/bin/hblock')
|
||||
os.system('chown 0:0 /usr/local/bin/hblock')
|
||||
os.system('chmod 755 /usr/local/bin/hblock')
|
||||
os.system('hblock -S none -D none exit 0')
|
||||
|
||||
## this function may not be necessary because the bug is already fixed
|
||||
## in live-build.
|
||||
def manage_raspi_firmware():
|
||||
"""
|
||||
Manage when the raspi firmware, is removed.
|
||||
"""
|
||||
if os.path.exists("/usr/share/peppermint/pep_id"):
|
||||
os.system("apt remove raspi-firmware -y")
|
||||
os.system("apt purge raspi-firmware -y")
|
||||
os.system("apt autoremove -y")
|
||||
else:
|
||||
print("not there")
|
||||
|
||||
|
||||
def manage_symlinks():
|
||||
"""
|
||||
Symlink management
|
||||
"""
|
||||
# Workaround for using snapd on debian. Thank You - @stevesveryown.
|
||||
os.system('[ ! -e /etc/skel/.local/share ] && mkdir -p /etc/skel/.local/share')
|
||||
os.system('ln -s snap /usr/bin/snap-store')
|
||||
# These are for the 3 installer scripts - icons.sh, themes.sh & walls.sh
|
||||
# In 0610- we set the permissions to 777 on the DIRECTORY, not the contents.
|
||||
os.system('ln -s icons /usr/share/pepicons')
|
||||
os.system('ln -s themes /usr/share/pepthemes')
|
||||
os.system('ln -s backgrounds /usr/share/pepwallpaper')
|
||||
|
||||
|
||||
def set_vi_vim():
|
||||
"""
|
||||
Setting the better version of vim
|
||||
"""
|
||||
# A better version of vi and vim than vim-tiny
|
||||
os.system('rm /etc/alternatives/vi')
|
||||
os.system('ln -s ../../etc/alternatives/vim /usr/bin/vim')
|
||||
os.system('ln -s ../../usr/bin/vim.tiny /etc/alternatives/vim')
|
||||
os.system('ln -s ../../usr/bin/busybox /etc/alternatives/vi')
|
||||
|
||||
|
||||
def setting_permissions():
|
||||
"""
|
||||
This allows write access to the Welcome Screen database to users
|
||||
in the "cdrom" group. IF this a system wide file, one user can
|
||||
disable or turn it off for *ALL* accounts. If this is meant to be
|
||||
on a per user basis, put the .db in ${HOME}/.config . Or rewrite
|
||||
welcome.py to write to the .db WHICH user requested to disable
|
||||
this feature. Set Permissions on desktop files
|
||||
"""
|
||||
# Desktop links
|
||||
os.system('chmod 755 /usr/share/applications/Welcome.desktop')
|
||||
os.system('chmod 755 /usr/share/applications/plank.desktop')
|
||||
os.system('chmod 755 /usr/share/applications/kumo.desktop')
|
||||
os.system('chmod 755 /usr/share/applications/calamares-install-peppermint.desktop')
|
||||
# Executables
|
||||
os.system('chmod 755 /usr/local/bin/xDaily')
|
||||
os.system('chmod 755 /usr/local/bin/kumo')
|
||||
os.system('chmod 755 /usr/local/bin/welcome')
|
||||
os.system('chmod 755 /usr/bin/install-peppermint')
|
||||
os.system('chmod 755 /opt/pepconf/*')
|
||||
# Set permissions on the Python libs
|
||||
os.system('chmod 755 -R /usr/lib/python3/dist-packages/tendo')
|
||||
os.system('chmod 755 -R /usr/lib/python3/dist-packages/tendo-0.3.0.dist-info')
|
||||
os.system('chmod 755 -R /usr/lib/python3/dist-packages/ttkbootstrap')
|
||||
os.system('chmod 755 -R /usr/lib/python3/dist-packages/ttkbootstrap-1.10.1.dist-info')
|
||||
os.system('chmod 755 -R /usr/lib/python3/dist-packages/ttkcreator')
|
||||
# Set permissions on the lines theme
|
||||
os.system('chmod 755 -R /usr/share/desktop-base/lines-theme')
|
||||
# Set Grub Themes Permission
|
||||
os.system('chmod 755 -R /boot/grub/themes')
|
||||
# Set the Calamares Permissions]
|
||||
os.system('chmod 755 -R /etc/calamares')
|
||||
### After installation, additional groups to add new users to.
|
||||
os.system('grep -B99 "#EXTRA_GROUPS=" /etc/adduser.conf' +
|
||||
'> /etc/adduser.conf.new')
|
||||
os.system('grep "#EXTRA_GROUPS=" /etc/adduser.conf' +
|
||||
' | cut -c2-' +
|
||||
'>> /etc/adduser.conf.new'
|
||||
)
|
||||
os.system('grep -B3 "#ADD_EXTRA_GROUPS=" /etc/adduser.conf >> /etc/adduser.conf.new')
|
||||
os.system('grep "#ADD_EXTRA_GROUPS=" /etc/adduser.conf | cut -c2- >> /etc/adduser.conf.new')
|
||||
os.system('grep -B3 "#NAME_REGEX=" /etc/adduser.conf >> /etc/adduser.conf.new')
|
||||
# These are for the 3 installer scripts - icons.sh, themes.sh & walls.sh
|
||||
# In 0600- we created symlinks to these directories. This makes them writable.
|
||||
os.system('chmod 755 -R /usr/share/icons')
|
||||
os.system('chmod 755 -R /usr/share/themes')
|
||||
os.system('chmod 755 -R /usr/share/backgrounds')
|
||||
os.system('chmod 755 -R /usr/share/pixmaps')
|
||||
|
||||
|
||||
def final_cleanup():
|
||||
"""
|
||||
This section is the "lint-trap" to remove files and/or
|
||||
directories not associated with or required by PepOS.
|
||||
Followed by "\" , add files to be removed, one per line.
|
||||
"""
|
||||
files_to_remove = [ "/usr/bin/install-debian",
|
||||
"/usr/share/applications/min.desktop",
|
||||
"/usr/share/applications/calamares-install-debian.desktop"
|
||||
]
|
||||
for file_path in files_to_remove:
|
||||
if os.path.exists(file_path):
|
||||
os.system(f"rm -rf {file_path}")
|
||||
print(f" Removed: {file_path}")
|
||||
else:
|
||||
print(f" The path {file_path} was not found and couldn't be removed.")
|
||||
### This might be better in an OS-tweaks hook script.
|
||||
# Lowers the footprint in RAM by 200 MB at the small expense of added size to the ISO.
|
||||
os.system('update-icon-caches /usr/share/icons/*')
|
||||
### Setting --apt-recommends and --apt-suggests defaults to '0'
|
||||
# Create and write to the file
|
||||
os.system('echo "# Changing these values to \\"1\\" may quickly fill up a small partition" > /etc/apt/apt.conf.d/99No-Recommends')
|
||||
# Append additional content to the file
|
||||
os.system('echo "APT::Install-Recommends \\"0\\";\nAPT::Install-Suggests \\"0\\";" >> /etc/apt/apt.conf.d/99No-Recommends')
|
||||
### Fixes the "Not installing grub for UEFI Secure Boot" in all versions , after the default was changed.
|
||||
#sed s/keyutils/"keyutils --install-recommends"/ /usr/sbin/bootloader-config > /tmp/bootloader-config
|
||||
os.system('echo -e "$(grep -A1 -B20 "Installing grub-efi (uefi)..." /usr/sbin/bootloader-config) --install-recommends" > /tmp/bootloader-config')
|
||||
os.system('echo -e "$(grep -A2 "else" /usr/sbin/bootloader-config) --install-recommends\nfi" >> /tmp/bootloader-config')
|
||||
os.system('chmod +x /tmp/bootloader-config && mv /tmp/bootloader-config /usr/sbin/bootloader-confi')
|
||||
|
||||
|
||||
def rename_kernel():
|
||||
"""
|
||||
These commands are typically used in the context of updating the
|
||||
initial ramdisk image and the kernel image for a live Linux system.
|
||||
The steps can be summarized as follows:
|
||||
Removal of the current boot files: initrd.img and vmlinuz are
|
||||
removed to clear out the old versions.
|
||||
Copying the updated versions: New versions of these files,
|
||||
which match the patterns initrd.img-* and vmlinuz-*, are copied
|
||||
to the standard names initrd.img and vmlinuz.
|
||||
"""
|
||||
os.system('rm live/initrd.img')
|
||||
os.system('rm live/vmlinuz')
|
||||
os.system('cp live/initrd.img-* live/initrd.img')
|
||||
os.system('cp live/vmlinuz-* live/vmlinuz')
|
||||
|
||||
|
||||
def start():
|
||||
""" This will begin the execution process of the hooks
|
||||
First see what arch is being ran and run the correct
|
||||
functions
|
||||
"""
|
||||
architecture = platform.architecture()[0]
|
||||
if '64bit' in architecture:
|
||||
apt_install_packages()
|
||||
remove_packages_from_the_build()
|
||||
install_librewolf_browser()
|
||||
remove_desktop_files()
|
||||
setup_plymouth_theme_grub()
|
||||
hblock_setup()
|
||||
manage_raspi_firmware()
|
||||
manage_symlinks()
|
||||
set_vi_vim()
|
||||
setting_permissions()
|
||||
final_cleanup()
|
||||
rename_kernel()
|
||||
else:
|
||||
apt_install_packages()
|
||||
remove_desktop_files()
|
||||
remove_packages_from_the_build()
|
||||
setup_plymouth_theme_grub()
|
||||
hblock_setup()
|
||||
manage_raspi_firmware()
|
||||
manage_symlinks()
|
||||
set_vi_vim()
|
||||
setting_permissions()
|
||||
final_cleanup()
|
||||
rename_kernel()
|
||||
|
||||
|
||||
start()
|
|
@ -1,155 +0,0 @@
|
|||
"""
|
||||
* Author: "PeppermintOS Team(peppermintosteam@proton.me)
|
||||
*
|
||||
* License: SPDX-License-Identifier: GPL-3.0-or-later
|
||||
*
|
||||
* This hook is the central one used for the live session
|
||||
* Add things as needed
|
||||
"""
|
||||
import os
|
||||
import subprocess
|
||||
|
||||
def cmdline():
|
||||
""" Function to read kernel command line parameters """
|
||||
global LIVE_USER_DEFAULT_GROUPS, LIVE_USER_FULLNAME, LIVE_USERNAME
|
||||
LIVE_USER_DEFAULT_GROUPS = ""
|
||||
LIVE_USER_FULLNAME = ""
|
||||
LIVE_USERNAME = ""
|
||||
|
||||
# Read kernel command line parameters
|
||||
with open("/proc/cmdline", "r") as f:
|
||||
cmdline_params = f.read().split()
|
||||
|
||||
for param in cmdline_params:
|
||||
if "live-config.user-default-groups=" in param or "user-default-groups=" in param:
|
||||
LIVE_USER_DEFAULT_GROUPS = param.split('=')[-1]
|
||||
elif "live-config.user-fullname=" in param or "user-fullname=" in param:
|
||||
LIVE_USER_FULLNAME = param.split('=')[-1]
|
||||
elif "live-config.username=" in param or "username=" in param:
|
||||
LIVE_USERNAME = param.split('=')[-1]
|
||||
|
||||
|
||||
def pkg_is_installed(pkg_name):
|
||||
""" Function to check if a package is installed """
|
||||
result = subprocess.run(['dpkg', '-s', pkg_name], stdout=subprocess.PIPE,
|
||||
stderr=subprocess.PIPE)
|
||||
return result.returncode == 0
|
||||
|
||||
|
||||
def component_was_executed(component_name):
|
||||
""" Function to check if a component was executed """
|
||||
return os.path.exists(f"/var/lib/live/config/{component_name}")
|
||||
|
||||
|
||||
def init():
|
||||
""" Initialization function """
|
||||
if not pkg_is_installed("user-setup") or component_was_executed("user-setup"):
|
||||
exit(0)
|
||||
print(" user-setup", end='')
|
||||
|
||||
|
||||
def config():
|
||||
""" Configuration function """
|
||||
global LIVE_USER_DEFAULT_GROUPS
|
||||
|
||||
# Check if user is already configured
|
||||
with open("/etc/passwd", "r") as f:
|
||||
if any(LIVE_USERNAME in line for line in f):
|
||||
exit(0)
|
||||
|
||||
# Adjust formatting of groups
|
||||
if LIVE_USER_DEFAULT_GROUPS:
|
||||
LIVE_USER_DEFAULT_GROUPS = LIVE_USER_DEFAULT_GROUPS.replace(",", " ")
|
||||
|
||||
# Make sure user is not in sudo group if sudo is disabled
|
||||
if os.getenv("LIVE_CONFIG_NOROOT") == "true":
|
||||
LIVE_USER_DEFAULT_GROUPS = LIVE_USER_DEFAULT_GROUPS.replace("sudo", "")
|
||||
|
||||
# Default password is 'U6aMy0wojraho' (blank password)
|
||||
_PASSWORD = "U6aMy0wojraho"
|
||||
|
||||
# Write configuration to temporary file
|
||||
with open("/tmp/live-config.cfg", "w") as f:
|
||||
f.write(f"""user-setup passwd/make-user boolean true
|
||||
user-setup passwd/root-password-crypted string *
|
||||
user-setup passwd/user-password-crypted string {_PASSWORD}
|
||||
user-setup passwd/user-default-groups string {LIVE_USER_DEFAULT_GROUPS}
|
||||
user-setup passwd/user-fullname string {LIVE_USER_FULLNAME}
|
||||
user-setup passwd/username string {LIVE_USERNAME}
|
||||
user-setup passwd/user-uid string 1000
|
||||
""")
|
||||
|
||||
# Apply configuration
|
||||
subprocess.run(['debconf-set-selections', '<', '/tmp/live-config.cfg'],
|
||||
shell=True)
|
||||
os.remove("/tmp/live-config.cfg")
|
||||
|
||||
# Workaround for bug in shadow
|
||||
result = subprocess.run(['/usr/lib/user-setup/user-setup-apply'],
|
||||
stderr=subprocess.PIPE)
|
||||
for line in result.stderr.decode().split('\n'):
|
||||
if "Shadow passwords are now on" not in line:
|
||||
print(line)
|
||||
|
||||
# Creating state file
|
||||
with open("/var/lib/live/config/user-setup", "w") as f:
|
||||
f.write("")
|
||||
|
||||
|
||||
def set_plymouth():
|
||||
"""
|
||||
1. set the plymouth on boot
|
||||
2. Remove the defauly theme
|
||||
3. Re added the new default theme
|
||||
"""
|
||||
source = '/usr/share/desktop-base/joy-theme'
|
||||
destination = '/etc/alternatives/desktop-theme'
|
||||
|
||||
os.system('plymouth-set-default-theme -R joy')
|
||||
os.system('rm -f /etc/alternatives/desktop-theme')
|
||||
os.system(f'ln -sf {source} {destination}')
|
||||
|
||||
|
||||
def set_installer_permissions():
|
||||
"""
|
||||
set permmissions needed for general install
|
||||
"""
|
||||
source = '/usr/share/desktop-base/joy-theme'
|
||||
destination = '/etc/alternatives/desktop-theme'
|
||||
makelnk = f'ln -sf {source} {destination}'
|
||||
|
||||
os.system('chmod 755 /usr/bin/install-peppermint')
|
||||
os.system('chmod 755 /usr/share/applications/calamares-install-peppermint.desktop')
|
||||
os.system(makelnk)
|
||||
os.system('chmod 755 -R /boot/grub/themes')
|
||||
os.system('cd /opt')
|
||||
os.system('curl -LO https://calamares.io/deploycala.py')
|
||||
os.system('python3 deploycala.py')
|
||||
|
||||
|
||||
def other_misc_settings():
|
||||
"""
|
||||
Other settings as needed
|
||||
"""
|
||||
source ="/usr/share/desktop-base/active-theme/grub/pep-grub-16x9.png"
|
||||
destination = "/etc/alternatives/desktop-grub"
|
||||
makelnk = f'ln -sf {source} {destination}'
|
||||
# Remove the grub symlink for the background
|
||||
os.system('rm -f /etc/alternatives/desktop-grub')
|
||||
# Then recreate it with the Pep Background
|
||||
os.system(makelnk)
|
||||
|
||||
|
||||
def remmove_desktop_files():
|
||||
"""
|
||||
Use this def to remove any .desktop files you donot need
|
||||
"""
|
||||
os.system('rm /usr/share/applications/btop.desktop')
|
||||
|
||||
# Main execution
|
||||
cmdline()
|
||||
init()
|
||||
config()
|
||||
set_plymouth()
|
||||
set_installer_permissions()
|
||||
remmove_desktop_files()
|