Moved from ./install/todo

This commit is contained in:
Anthony Axenov 2022-07-04 22:13:41 +08:00
parent 317f635b91
commit 5970e9b968
Signed by: anthony
GPG Key ID: EA9EC32FF7CCD4EC
5 changed files with 161 additions and 0 deletions

12
experimental/flatpak Executable file
View File

@ -0,0 +1,12 @@
#!/bin/bash
echo
echo "==============================================="
echo "Installing flatpak and its software..."
echo "==============================================="
echo
sudo apt install -y --autoremove \
flatpak \
gnome-software-plugin-flatpak
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo

49
experimental/oci8 Normal file
View File

@ -0,0 +1,49 @@
#!/bin/bash
echo
echo "==============================================="
echo "Installing oci8..."
echo "==============================================="
echo
# https://www.oracle.com/cis/database/technologies/instant-client/downloads.html
#check for
# wget https://download.oracle.com/otn_software/linux/instantclient/instantclient-basic-linuxx64.zip
# wget https://download.oracle.com/otn_software/linux/instantclient/instantclient-basiclite-linuxx64.zip -- only libociicus.so
# wget https://download.oracle.com/otn_software/linux/instantclient/instantclient-sqlplus-linuxx64.zip
# wget https://download.oracle.com/otn_software/linux/instantclient/instantclient-tools-linuxx64.zip
# wget https://download.oracle.com/otn_software/linux/instantclient/instantclient-sdk-linuxx64.zip
#unzip
sudo mkdir /opt/oracle/
sudo mv ~/Downloads/instant_client/ /opt/oracle/
sudo sh -c "echo /opt/oracle/instant_client > /etc/ld.so.conf.d/oracle-instantclient.conf"
sudo ldconfig
sudo apt install -y --autoremove \
php-dev \
php-pear \
build-essential \
libaio1 \
default-jdk
sudo pecl channel-update pecl.php.net
sudo pecl install oci8 # php8
#sudo pecl install oci8-2.2.0 # php7
#sh -c "echo '; priority=10' > /etc/php/7.4/mods-available/oci8.ini"
# sudo sh -c "echo 'extension=oci8.so' >> /etc/php/7.4/mods-available/oci8.ini"
# sudo chmod 0644 /etc/php/7.4/mods-available/oci8.ini
sudo phpenmod oci8
php -i | grep oci8
# instantclient,/opt/oracle/instant_client
# https://pecl.php.net/package/oci8
#sudo pecl install oci8-2.2.0

View File

@ -0,0 +1,42 @@
#!/bin/bash
echo
echo "==============================================="
echo "Installing phpstorm-url-handler..."
echo "==============================================="
echo
installed() {
command -v "$1" >/dev/null 2>&1
}
# https://github.com/rozwell/phpstorm-url-handler/
# https://askubuntu.com/a/1023143
# https://askubuntu.com/a/919825
# https://medium.com/swlh/custom-protocol-handling-how-to-8ac41ff651eb
# https://www.linuxquestions.org/questions/linux-desktop-74/xdg-open-doesn%27t-recognize-custom-protocol-4175433062/#post4809984
sudo rm -rf /usr/bin/phpstorm-url-handler >/dev/null
sudo rm -rf ~/.local/share/applications/phpstorm-url-handler.desktop >/dev/null
sudo rm -rf /usr/share/applications/phpstorm-url-handler.desktop >/dev/null
if installed "git"; then
sudo git clone https://github.com/rozwell/phpstorm-url-handler.git /usr/src/phpstorm-url-handler
else
sudo wget https://github.com/rozwell/phpstorm-url-handler/archive/master.zip -O /tmp/phpstorm-url-handler.zip
sudo unzip /tmp/phpstorm-url-handler.zip -d /usr/src/phpstorm-url-handler
sudo rm -f /tmp/phpstorm-url-handler.zip
fi
info "Copy .desktop"
sudo cp /usr/src/phpstorm-url-handler/phpstorm-url-handler.desktop /usr/share/local/applications/phpstorm-url-handler.desktop
info "Symlink bin"
sudo cp /usr/src/phpstorm-url-handler/phpstorm-url-handler /usr/bin/phpstorm-url-handler
info "desktop-file-install"
sudo desktop-file-install phpstorm-url-handler.desktop
info "update-desktop-database"
sudo update-desktop-database -v 2>&1 | grep -E "^(.+)\/phpstorm-url-handler.desktop(.+)$"
info "xdg-mime"
xdg-mime default phpstorm-url-handler.desktop x-scheme-handler/phpstorm

46
experimental/samp-server Normal file
View File

@ -0,0 +1,46 @@
#!/bin/bash
echo
echo "==============================================="
echo "Installing samp-server v03svr_R2-1..."
echo "==============================================="
echo
# https://sampwiki.blast.hk/wiki/Linux_Server
# https://team.sa-mp.com/wiki/Server.cfg_RU.html
cd $HOME
wget -qO - https://files.sa-mp.com/samp03svr_R2-1.tar.gz | tar -zxf -
# sudo dpkg --add-architecture i386
# sudo apt update
# sudo apt install -y libc6:i386
apt-get install ia32-libs
echo "echo Executing Server Config...
lanmode 0
rcon 1
language Russian
rcon_password bootsector
maxplayers 50
port 7777
hostname My Server
gamemode0 bare 1
filterscripts base gl_actions gl_property gl_realtime
announce 1
query 1
weburl
maxnpc 0
onfoot_rate 40
incar_rate 40
weapon_rate 40
stream_distance 800.0
stream_rate 1000
timestamp 1
output 0
" > $HOME/samp03/server.cfg
ln -s $HOME/samp03/samp03svr /usr/local/bin/samp
echo
echo "Success! Now run via 'samp &'"
echo

12
experimental/wkhtmltopdf Executable file
View File

@ -0,0 +1,12 @@
#!/bin/bash
echo
echo "==============================================="
echo "Installing wkhtmltopdf..."
echo "==============================================="
echo
# не тестировалось
wget "https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6-1/wkhtmltox_0.12.6-1.focal_amd64.deb" -O /tmp/wkhtmltopdf.deb
sudo dpkg -i /tmp/wkhtmltopdf.deb
rm /tmp/wkhtmltopdf.deb