Skip to content

Instantly share code, notes, and snippets.

View salaros's full-sized avatar
🎉
Making magic happen

Yaroslav Zhmayev salaros

🎉
Making magic happen
View GitHub Profile
@salaros
salaros / kmskeys10.txt
Created November 22, 2016 08:54 — forked from CHEF-KOCH/kmskeys10.txt
Windows 10 KMS Keys
Windows.10.and.Office.2016.gVLK
#####################################################################
# technet.microsoft.com/en-us/library/jj612867.aspx?lc=1033 #
#####################################################################
Windows 10 Professional W269N-WFGWX-YVC9B-4J6C9-T83GX
Windows 10 Professional N MH37W-N47XK-V7XM9-C7227-GCQG9
Windows 10 Education NW6C2-QMPVW-D7KKK-3GKT6-VCFB2
Windows 10 Education N 2WH4N-8QGBV-H22JP-CT43Q-MDWWJ
@salaros
salaros / changeScreenResolutionMacOS.sh
Created January 3, 2017 15:40
Change screen resolution on macOS VMWare instance
cd /Library/Application Support/VMware Tools
./vmware-resolutionSet 1920 1080
@salaros
salaros / speed_up_mysql_dump_import.sh
Created February 24, 2017 16:43
Modifies a MySQL dump file (.sql) in order to improve its importing speed a little bit
#!/bin/bash
sed -i '1s;^;\n;' $1
sed -i '1s;^;\n;' $1
sed -i '1s/^/SET autocommit=0;\n/' $1
sed -i '1s/^/SET unique_checks=0;\n/' $1
sed -i '1s/^/SET foreign_key_checks=0;\n/' $1
echo '' >> $1
@salaros
salaros / mediaqueries.css
Created April 11, 2017 10:50 — forked from phuphighter/mediaqueries.css
Semantic UI friendly media queries
/* Mobile */
@media only screen and (max-width: 767px) {
[class*="mobile hidden"],
[class*="tablet only"]:not(.mobile),
[class*="computer only"]:not(.mobile),
[class*="large screen only"]:not(.mobile),
[class*="widescreen only"]:not(.mobile),
[class*="or lower hidden"] {
display: none !important;
}
static int
HostIFGetUserPages(void *uvAddr, // IN
struct page **ppages, // OUT
unsigned int numPages) // IN
{
int retval;
down_read(&current->mm->mmap_sem);
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 9, 0)
unsigned int flags = 0;
@salaros
salaros / bootstrap-3.x-media-queries.css
Created June 26, 2017 22:59
Default sizes for Twitter Bootstrap 3.x media queries
/*========== Mobile First Method ==========*/
/* Custom, iPhone Retina */
@media only screen and (min-width : 320px) {
}
/* Extra Small Devices, Phones */
@media only screen and (min-width : 480px) {
/usr/bin/h3disp: illegal video mode "-m 720i". Try one of the following:
480i use "-m 480i" or "-m 0"
576i use "-m 576i" or "-m 1"
480p use "-m 480p" or "-m 2"
576p use "-m 576p" or "-m 3"
720p50 use "-m 720p50" or "-m 4"
720p60 use "-m 720p60" or "-m 5"
1080i50 use "-m 1080i50" or "-m 6"
1080i60 use "-m 1080i60" or "-m 7"
watch -n3 grep -i -e 'mhz' -e 'ghz' /proc/cpuinfo
watch -n3 "egrep -i 'mhz|ghz' /proc/cpuinfo"
Re-generate /etc/apt/sources.list on Ubuntu or Debian
https://repogen.simplylinux.ch/
https://debgen.simplylinux.ch/
@salaros
salaros / make_Nautilus_default.sh
Created September 21, 2017 14:14
make Nautilus default file browser
xdg-mime default nautilus.desktop inode/directory
gsettings set org.gnome.desktop.background show-desktop-icons true
exo-preferred-applications
update-mime-database $HOME/.local/share/mime/
sudo update-mime-database /usr/share/mime/