Skip to content

Instantly share code, notes, and snippets.

@nshtg
Last active January 31, 2016 00:17
Show Gist options
  • Save nshtg/8a73ff541c80bf072262 to your computer and use it in GitHub Desktop.
Save nshtg/8a73ff541c80bf072262 to your computer and use it in GitHub Desktop.
Clone the latest zsh sources and install them to /usr/local
#!/bin/sh
wget https://cmake.org/files/v3.4/cmake-3.4.3-Linux-x86_64.tar.gz -O /tmp/cmake.tar.gz
sudo tar --strip-components 1 -xzvf /tmp/cmake.tar.gz -C /usr/local
#!/bin/bash
set -e
sudo rm -rf /tmp/libressl*
sudo rm -rf /tmp/openssh*
curl --silent http://ftp.halifax.rwth-aachen.de/openbsd/LibreSSL/libressl-2.3.2.tar.gz -o /tmp/libressl.tar.gz
curl --silent ftp://ftp.hostserver.de/pub/OpenBSD/OpenSSH/portable/openssh-7.1p2.tar.gz -o /tmp/openssh.tar.gz
clear;
printf "Building LibreSSL..\n\n"
tar xzf /tmp/libressl.tar.gz -C /tmp
cd /tmp/libressl*
./configure --quiet
make -j 2 --quiet
sudo make install --quiet
sudo ldconfig
printf "..ok!\n"
printf "Building OpenSSH..\n\n"
tar xzf /tmp/openssh.tar.gz -C /tmp
cd /tmp/openssh*
./configure --prefix=/usr --sysconfdir=/etc/ssh --with-ssl-dir=/usr/local/lib --quiet
make -j 2 --quiet
sudo make install --quiet
sudo rm /etc/ssh/ssh_host_dsa*
sudo rm /etc/ssh/ssh_host_ecdsa*
sudo rm /etc/ssh/*.bak.*
printf "..ok!\n\n"
sudo systemctl restart sshd
printf "Done!\n"
#!/bin/sh
wget "https://nodejs.org/dist/latest/node-$(curl -L 'nodejs.org/dist/index.tab' | sed -n '2p' | awk '{ print $1 }')-linux-x64.tar.gz" -O /tmp/nodejs.tar.gz
sudo tar --strip-components 1 -xzvf /tmp/nodejs.tar.gz -C /usr/local
wget -O- https://raw.githubusercontent.com/glenpike/npm-g_nosudo/master/npm-g-nosudo.sh | sh
export PATH="$HOME/.npm-packages/bin:$PATH"
sudo chown -R $USER:$USER "$HOME/.npm-packages"
rehash
npm install -g npm@latest
npm install -g coffee-script
npm install -g pm2
#!/bin/bash
set -e
sudo rm -rf /tmp/openssh*
curl --silent ftp://ftp.hostserver.de/pub/OpenBSD/OpenSSH/portable/openssh-7.1p2.tar.gz -o /tmp/openssh.tar.gz
clear;
printf "Building OpenSSH...\n"
tar xzf /tmp/openssh.tar.gz -C /tmp
cd /tmp/openssh*
./configure --prefix=/usr --sysconfdir=/etc/ssh --quiet
make -j 2 --quiet
sudo make install --quiet
sudo rm /etc/ssh/ssh_host_dsa*
sudo rm /etc/ssh/ssh_host_ecdsa*
sudo rm /etc/ssh/*.bak.*
printf "..ok!\n\n"
sudo systemctl restart sshd
printf "Done!\n"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment