Skip to content

Instantly share code, notes, and snippets.

View jordanilchev's full-sized avatar

Jordan Ilchev jordanilchev

View GitHub Profile
(source: https://answers.microsoft.com/en-us/windows/forum/all/reverse-mouse-wheel-scroll/657c4537-f346-4b8b-99f8-9e1f52cd94c2)
To set the scroll direction of your mouse, do the following steps:
Step 1: Open Windows PowerShell in Administrator Mode. You can do this by going to Start Menu, type PowerShell, and click Run as Administrator.
Step 2: Copy the following code and paste it in the command line of Windows PowerShell:
$mode = Read-host "How do you like your mouse scroll (0 or 1)?"; Get-PnpDevice -Class Mouse -PresentOnly -Status OK | ForEach-Object { "$($_.Name): $($_.DeviceID)"; Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Enum\$($_.DeviceID)\Device Parameters" -Name FlipFlopWheel -Value $mode; "+--- Value of FlipFlopWheel is set to " + (Get-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Enum\$($_.DeviceID)\Device Parameters").FlipFlopWheel + "`n" }
@jordanilchev
jordanilchev / kube-flannel.yml
Created November 23, 2019 17:09
kube-flannel.yml for 1.16.3
---
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1beta1
metadata:
name: flannel
rules:
- apiGroups:
- ""
resources:
- pods
@jordanilchev
jordanilchev / avahi.sh
Created February 16, 2019 19:15
Install avahi daemon on Ubuntu LTS so it can be reached with ubuntu-host-name.locla
sudo apt install avahi-daemon avahi-discover avahi-utils libnss-mdns mdns-scan
@jordanilchev
jordanilchev / setup steps.md
Last active September 23, 2018 12:29
Raspberry Pi3 Cluster with Docker and Kubernetes Sep.2018
@jordanilchev
jordanilchev / check 2factor for github
Created March 21, 2015 14:12
Check the Github Owners that do not have 2 Factor Authentication enabled
GET /orgs/[organization]/members?filter=2fa_disabled&role=admin&page=1&per_page=100
Host: api.github.com
Authorization: token [Token with proper permisions ;)]
Accept: application/vnd.github.moondragon+json
Cache-Control: no-cache
# ~/.bash_profile for root
# usage:
# cd && curl -o .bash_profile https://gist.githubusercontent.com/jordanilchev/bc374fcd81bf395ef88a/raw && source .bash_profile
if [ "$BASH" ]; then
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
fi
# To install:
# curl https://gist.githubusercontent.com/jordanilchev/a9dd04b6015510dd7a92/raw > .bash_profile
# Git branch helper function
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ \1 /'
}
# Colorized multiline prompt
export PS1="\n\e[0;32m[\u@\h] \e[37m\]\w \e[30;44m\$(parse_git_branch)\e[0m\n>"
PS1="\n[\u@\h] \w\n>"
color:
PS1="\n\e[0;36m[\u@\h] \e[m\w\n>"
@jordanilchev
jordanilchev / index.html
Last active August 29, 2015 13:59
A Pen by Jordan Ilchev.
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="format-detection" content="telephone=no" />
<meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=device-dpi" />
<link rel="stylesheet" type="text/css" href="css/index.css" />
<title>Hello World!</title>
</head>
<body>
@jordanilchev
jordanilchev / jsHintOptions.xml
Last active December 22, 2015 03:49
jsLint options for http://jslint4vs2010.codeplex.com/ jsLint VS extension
<?xml version="1.0"?>
<Options xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Enabled>true</Enabled>
<ErrorCategory>Error</ErrorCategory>
<TODOEnabled>false</TODOEnabled>
<TODOCategory>Task</TODOCategory>
<RunOnBuild>false</RunOnBuild>
<CancelBuildOnError>false</CancelBuildOnError>
<JSLintOptions>
<BoolOptions2>