Skip to content

Instantly share code, notes, and snippets.

@archie9211
archie9211 / mycolab_init.sh
Last active June 7, 2019 14:15
mycolab_init.sh
sudo apt update
# sudo apt upgrade
sudo apt install git vim curl
sudo apt install zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
mkdir /root/.vim
curl -o "/root/.vim/vimrc" "https://raw.githubusercontent.com/archie9211/scripts/8fcfba08135823635112748dee14bb262214768b/vimrc"
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
mv /root/.zshrc /root/.zshrc.bak
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://archive.ubuntu.com/ubuntu/ bionic main restricted
# deb-src http://archive.ubuntu.com/ubuntu/ bionic main restricted
## Major bug fix updates produced after the final release of the
## distribution.
deb http://archive.ubuntu.com/ubuntu/ bionic-updates main restricted
# deb-src http://archive.ubuntu.com/ubuntu/ bionic-updates main restricted
#! /bin/sh
#Kernel building script
function colors {
blue='\033[0;34m' cyan='\033[0;36m'
yellow='\033[0;33m'
red='\033[0;31m'
@archie9211
archie9211 / colab-ssh-jupyter.sh
Last active August 27, 2021 13:26
Google colab ssh and jupyter lab script
# create an account on ngrok is not already and copy the authtoken and
wget https://bin.equinox.io/c/4VmDzA7iaHb/ngrok-stable-linux-amd64.zip
unzip ngrok-stable-linux-amd64.zip
read -p 'Enter the authtoken from ngrok :' authtoken
./ngrok authtoken $authtoken #for example ZT64bWYnXTAsJej4FNFTdsjhsuAQqKqZHn2Sh4g2sfAD
./ngrok tcp 22 &
apt-get install -qq -o=Dpkg::Use-Pty=0 openssh-server pwgen > /dev/null
mkdir -p /var/run/sshd
echo "PermitRootLogin yes" >> /etc/ssh/sshd_config && echo "PasswordAuthentication yes" >> /etc/ssh/sshd_config
echo "LD_LIBRARY_PATH=/usr/lib64-nvidia" >> /root/.bashrc && echo "export LD_LIBRARY_PATH" >> /root/.bashrc
#! /bin/sh
set -e o pipefail
KERNEL_DIR=$PWD
TG_BOT_TOKEN=$1
CHATID=$2
PREFIX=$3
exports() {
export KBUILD_BUILD_USER="archie"
set -e o pipefail
echo "script ran"
[net]
# Testing
# batch=1
# subdivisions=1
# Training
batch=64
subdivisions=16
width=416
height=416
channels=3
[net]
# Testing
# batch=1
# subdivisions=1
# Training
batch=64
subdivisions=16
width=416
height=416
channels=3
@archie9211
archie9211 / tstp.py
Created July 22, 2020 23:48
Userge Bot plugin for torrent search from torrent-paradise.ml
# Userge Plugin for Torrent Search from torrent-paradise.ml
# Author: Nageen (https://github.com/archie9211) (@archie9211)
# All rights reserved
import requests
from userge import userge, Message
import re
def getsize(len_of_file):
len_of_file = int(len_of_file)
depth = 0