Skip to content

Instantly share code, notes, and snippets.

View naspeh's full-sized avatar

Hrisha Kostiuk naspeh

View GitHub Profile
@softmoth
softmoth / arch-linux-install
Last active January 16, 2023 13:55 — forked from mattiaslundberg/arch-linux-install
Minimal instructions for installing arch linux on an UEFI system with full system encryption using dm-crypt and luks
# Install ARCH Linux with encrypted file-system and EFI on 8,2 MacBook.
# The official installation guide contains a more verbose description:
# https://wiki.archlinux.org/index.php/Installation_Guide
# Resize "Macintosh HD" to make room for Linux. This works live, including with
# whole-disk encryption (WDE, FileVault). Ensure backups are current, of course,
# before proceeding
diskutil list
diskutil cs list
# Ensure all data will fit in 250G, with some to spare!
@dmnsgn
dmnsgn / .eslintrc.js
Created July 23, 2015 13:31
.eslintrc Google JavaScript Style Guide (eslint v0.24.1)
{
// http://eslint.org/docs/rules/
"env": {
"browser": true, // browser global variables.
"node": false, // Node.js global variables and Node.js-specific rules.
"worker": false, // web workers global variables.
"amd": false, // defines require() and define() as global variables as per the amd spec.
"mocha": false, // adds all of the Mocha testing global variables.
"jasmine": false, // adds all of the Jasmine testing global variables for version 1.3 and 2.0.
@staltz
staltz / introrx.md
Last active July 25, 2024 16:52
The introduction to Reactive Programming you've been missing
@mattiaslundberg
mattiaslundberg / arch-linux-install
Last active May 26, 2024 17:26
Minimal instructions for installing arch linux on an UEFI system with full system encryption using dm-crypt and luks
# Install ARCH Linux with encrypted file-system and UEFI
# The official installation guide (https://wiki.archlinux.org/index.php/Installation_Guide) contains a more verbose description.
# Download the archiso image from https://www.archlinux.org/
# Copy to a usb-drive
dd if=archlinux.img of=/dev/sdX bs=16M && sync # on linux
# Boot from the usb. If the usb fails to boot, make sure that secure boot is disabled in the BIOS configuration.
# Set swedish keymap
@XVilka
XVilka / TrueColour.md
Last active July 9, 2024 23:28
True Colour (16 million colours) support in various terminal applications and terminals

THIS GIST WAS MOVED TO TERMSTANDARD/COLORS REPOSITORY.

PLEASE ASK YOUR QUESTIONS OR ADD ANY SUGGESTIONS AS A REPOSITORY ISSUES OR PULL REQUESTS INSTEAD!

@plentz
plentz / nginx.conf
Last active July 25, 2024 09:38
Best nginx configuration for improved security(and performance)
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@gnarf
gnarf / ..git-pr.md
Last active April 12, 2024 22:00
git pr - Global .gitconfig aliases for Pull Request Managment

Install

Either copy the aliases from the .gitconfig or run the commands in add-pr-alias.sh

Usage

Easily checkout local copies of pull requests from remotes:

  • git pr 4 - creates local branch pr/4 from the github upstream(if it exists) or origin remote and checks it out
  • git pr 4 someremote - creates local branch pr/4 from someremote remote and checks it out
@asvetlov
asvetlov / hack.py
Created October 29, 2012 20:42
Hack to print Russian letters in unittests
# -*- encoding: utf-8 -*-
import unittest
class TestSomething(unittest.TestCase):
def test_unicode(self):
self.assertEqual(u'Русский', u'Текст')
if __name__ == '__main__':
import sys
import json
from json.decoder import JSONArray
from json.scanner import py_make_scanner
class UnorderedList(list):
"""
Works like a normal list, except the order of elements doesn't matter on
comparison