From d659c8b286be93cc008c40ddf9030172b00a69f5 Mon Sep 17 00:00:00 2001 From: lastdragon Date: Sun, 6 Sep 2026 11:06:16 -0600 Subject: [PATCH] Script para Debian 13 trixie --- initrepolastdragon.sh | 92 ++++++++++++++++++++++++++++++++++++++++++ initupdatesystemctl.sh | 20 +++++---- 2 files changed, 105 insertions(+), 7 deletions(-) create mode 100755 initrepolastdragon.sh diff --git a/initrepolastdragon.sh b/initrepolastdragon.sh new file mode 100755 index 0000000..02c1129 --- /dev/null +++ b/initrepolastdragon.sh @@ -0,0 +1,92 @@ +#! /bin/bash + +cat > /etc/apt/sources.list << EOF + +deb http://repo.linuxdebian.mx/debian/ trixie main non-free-firmware non-free contrib +deb-src http://repo.linuxdebian.mx/debian/ trixie main non-free-firmware non-free contrib + +deb http://security.debian.org/debian-security trixie-security main non-free-firmware +deb-src http://security.debian.org/debian-security trixie-security main non-free-firmware + +deb http://repo.linuxdebian.mx/debian/ trixie-updates main non-free-firmware +deb-src http://repo.linuxdebian.mx/debian/ trixie-updates main non-free-firmware + + +EOF + +apt update +apt upgrade -y +apt install firmware-linux firmware-linux-free firmware-linux-nonfree firmware-misc-nonfree -y +apt install neovim -y +echo "set mouse-=a" >> ~/.vimrc + +# Instalando sistemas de archivo +apt install xfsprogs -y +apt install jfsutils -y +apt install exfat-fuse -y +apt install ntfs-3g -y +apt install dosfstools -y +apt install btrfs-progs -y + +cat > /usr/lib/systemd/system/autoexec.service << EOF +[Unit] +Description=Autoexec de servicios de Last Dragon +[Service] +Type=oneshot +ExecStart=/bin/autoexec +ExecStop=/bin/autoexecdown +RemainAfterExit=yes +[Install] +WantedBy=multi-user.target +EOF + +cat > /bin/autoexec << EOF +#! /bin/bash +EOF + +cat > /bin/autoexecdown << EOF +#! /bin/bash +EOF + +systemctl enable autoexec +chmod +x /bin/autoexec +chmod +x /bin/autoexecdown + +cat > /root/.bashrc << EOF +# ~/.bashrc: executed by bash(1) for non-login shells. + +# Note: PS1 and umask are already set in /etc/profile. You should not +# need this unless you want different defaults for root. +# PS1='${debian_chroot:+($debian_chroot)}\h:\w\$ ' +# umask 022 + + +alias cp='cp -i' +alias egrep='egrep --color=auto' +alias fgrep='fgrep --color=auto' +alias grep='grep --color=auto' +alias l.='ls -d .* --color=auto' +alias ll='ls -l --color=auto' +alias ls='ls --color=auto' +alias mv='mv -i' +alias rm='rm -i' +alias which='(alias; declare -f) | /usr/bin/which --tty-only --read-alias --read-functions --show-tilde --show-dot' +alias xzegrep='xzegrep --color=auto' +alias xzfgrep='xzfgrep --color=auto' +alias xzgrep='xzgrep --color=auto' +alias zegrep='zegrep --color=auto' +alias zfgrep='zfgrep --color=auto' +alias zgrep='zgrep --color=auto' +EOF + +#Hora UTC +#timedatectl set-local-rtc 0 --adjust-system-clock +#timedatectl set-timezone America/Mexico_City + +#Usar la hora de BIOS + +timedatectl set-local-rtc 1 --adjust-system-clock + +systemctl disable apparmor + +shutdown -r now diff --git a/initupdatesystemctl.sh b/initupdatesystemctl.sh index 84ca348..2d34606 100755 --- a/initupdatesystemctl.sh +++ b/initupdatesystemctl.sh @@ -2,14 +2,14 @@ cat > /etc/apt/sources.list << EOF -deb http://deb.debian.org/debian/ bookworm main non-free-firmware non-free contrib -deb-src http://deb.debian.org/debian/ bookworm main non-free-firmware non-free contrib +deb http://deb.debian.org/debian/ trixie main non-free-firmware non-free contrib +deb-src http://deb.debian.org/debian/ trixie main non-free-firmware non-free contrib -deb http://security.debian.org/debian-security bookworm-security main non-free-firmware -deb-src http://security.debian.org/debian-security bookworm-security main non-free-firmware +deb http://security.debian.org/debian-security trixie-security main non-free-firmware +deb-src http://security.debian.org/debian-security trixie-security main non-free-firmware -deb http://deb.debian.org/debian/ bookworm-updates main non-free-firmware -deb-src http://deb.debian.org/debian/ bookworm-updates main non-free-firmware +deb http://deb.debian.org/debian/ trixie-updates main non-free-firmware +deb-src http://deb.debian.org/debian/ trixie-updates main non-free-firmware EOF @@ -78,7 +78,13 @@ alias zfgrep='zfgrep --color=auto' alias zgrep='zgrep --color=auto' EOF -timedatectl set-timezone America/Mexico_City +#Hora UTC +#timedatectl set-local-rtc 0 --adjust-system-clock +#timedatectl set-timezone America/Mexico_City + +#Usar la hora de BIOS + +timedatectl set-local-rtc 1 --adjust-system-clock systemctl disable apparmor