Skip to content

Instantly share code, notes, and snippets.

@lazanet
lazanet / bootcampDownloader.js
Created December 14, 2018 14:19
Download mp3's from Bootcamp
// PASTE FOLLOWING LINES IN CONSOLE (CTRL + SHIFT + J), WHILE ON BOOTCAMP PAGE
numSongs = 0;
document.querySelectorAll(".play_status").forEach(function (button) {
button.click();
document.querySelectorAll(".title-col")[numSongs++].innerHTML += "<a href='" + document.querySelector("audio").src + "'>download</a>";
alert("Continue?");
});
if (numSongs == 0) // if it is a single song page
{
sudo apt-get install dosbox
скинути следећи zip и распаковати га на /opt/bc31
https://www.dropbox.com/s/1ql3gyuyxmylfca/bc31.zip?dl=0
Ископирати следећи ред на дно ~/.bashrc
alias dosenv='f(){ unset -f f; dosbox -c "mount c ." -c "mount d /opt/bc31" -c "PATH=%PATH%;D:\BIN" -c "c:" -c "cls" -c "$@" > /dev/null 2>&1 & }; f'
@lazanet
lazanet / LIST.H
Last active September 14, 2017 23:29
bcc3.1 list "template"
#ifndef __LIST_H__
#define __LIST_H__
#include <iostream.h>
#define makeNormalList(type) makeList(List_##type, type)
#define makePointerList(t) makeList(List_pointer##t, t *)
#define makeList(name, type)\
class name {\
@lazanet
lazanet / .emacs
Last active January 6, 2020 17:47
; Various settings:
(package-initialize)
(cua-mode 1) ;; Enable ^Z, ^X, ^C, ^V, select with mouse and shift-cursor-movement
(transient-mark-mode 1) ;; No region when it is not highlighted
(setq cua-keep-region-after-copy t) ;; Standard MS-Windows behaviour
(setq-default line-spacing 1) ;; Add 1 pixel between lines
(recentf-mode) ;; Add menu-item "File--Open recent"
; Define some additional "native-Windows" keystrokes (^tab, Alt/F4, ^A, ^F, ^O,
; ^S, ^W) and redefine (some of) the overridden Emacs functions.
#Xash3D pull + build on ubuntu 15.10
# by lazanet
# run with sudo
###############################
clear
rm -rdf dep
mkdir dep
cd dep
@lazanet
lazanet / xash3dbuild.sh
Created October 26, 2015 23:42
Xash 3D pull + build (Ubuntu)
#Xash3D pull + build on ubuntu
# by lazanet
###############################
sudo su
apt-get install cmake libc6-dev-i386 g++-4.6-multilib lib32bz2-dev libc6-dev-i386 lib32z1-dev lib32z1 lib32ncurses5 lib32bz2-1.0 libx11-dev xorg-dev
cd /opt
git clone https://github.com/SDLash3D/halflife
#!/usr/bin/env bash
# Wayback machine downloader
#TODO: Remove redundancy (download only newest files in given time period - not all of them and then write over them)
############################
clear
#Enter domain without http:// and www.
domain="google.com"
#Set matchType to "prefix" if you have multiple subdomains, or "exact" if you want only one page
matchType="domain"