Skip to content

Instantly share code, notes, and snippets.


Sergey Lukin sergeylukin

View GitHub Profile
w00fz /
Last active Dec 9, 2020
PHP switcher
# Check if command was ran as root.
if [[ $(id -u) -eq 0 ]]; then
echo "The command \"sphp\" should not be executed as root or via sudo directly."
echo "When a service requires root access, you will be prompted for a password as needed."
exit 1
# Usage
stak /
Created May 24, 2016
Remove Android Studio and all related files completely on OSX.
function confirm {
while :
echo -n "${MSG} [Y/N]: "
read ans
case $ans in
[yY]) return 0 ;;
lambdahands /
Created Sep 28, 2015
FlowType and CSS Modules


So basically FlowType doesn't know about CSS Modules, a really handy way of dealing with the plagues of CSS in codebases (global variables and dependency wackiness mainly).

What WebPack allows us to do is "require" CSS files and use their class names:

import styles from "my_styles.css";
import React from "react";
tahmidsadik / purgeAndroid.txt
Created Sep 19, 2015
How to completely remove Android Studio from Mac OS X
View purgeAndroid.txt
How to Completely Remove Android Studio
Execute these commands from the terminal
rm -Rf /Applications/Android\
rm -Rf ~/Library/Preferences/AndroidStudio*
rm ~/Library/Preferences/
rm -Rf ~/Library/Application\ Support/AndroidStudio*
rm -Rf ~/Library/Logs/AndroidStudio*
View button-set.css
.button {
margin-left: 10px;
.button:first-child {
margin-left: 0;
nadar / PostMessageToSlackChannel.php
Last active Oct 23, 2020
Post a message to a slack channel with PHP
View PostMessageToSlackChannel.php
* Send a Message to a Slack Channel.
* In order to get the API Token visit:
* The token will look something like this `xoxo-2100000415-0000000000-0000000000-ab1ab1`.
* @param string $message The message to post into a channel.
* @param string $channel The name of the channel prefixed with #, example #foobar
robertjpayne / RCTSwiftBridgeModule.h
Last active Sep 29, 2020
React Native - Swift Native Modules
View RCTSwiftBridgeModule.h
#import <Foundation/Foundation.h>
#import "RCTBridgeModule.h"
#define RCT_EXTERN_MODULE(objc_name, objc_supername) \
RCT_EXTERN_REMAP_MODULE(objc_name, objc_name, objc_supername)
#define RCT_EXTERN_REMAP_MODULE(js_name, objc_name, objc_supername) \
objc_name : objc_supername \
@end \
@interface objc_name (RCTExternModule) <RCTBridgeModule> \
drewwells / org.golang.doc.example.plist
Created Mar 26, 2015
Local godoc server for private packages. You will need to build the search index (periodically) to use search functionality.
View org.golang.doc.example.plist
?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC -//Apple Computer//DTD PLIST 1.0//EN >
<plist version="1.0">
<string>{YOUR GOPATH}</string>
barneycarroll / keepPasswordsHidden.css
Last active Dec 20, 2015
Stop Chrome popping up 'Show' buttons by your passwords.
View keepPasswordsHidden.css
#saved-passwords-list .list-inline-button {
display: none
bewest /
Last active Feb 28, 2017
using travis-ci to build using docpad, and publish to github pages

use travis-ci to publish to github



The docpad-plugin-ghpages uses the following information to stitch a new repo with contents of ./out directory onto root of your gh-pages branch:

  • git config
  • git config
You can’t perform that action at this time.