- Go to System Preferences -> Keyboard -> Modifier Keys...
- Change “Caps Lock” to “No action”
- Install Seil
- Change the Caps Lock key in Seil to keyCode 80 (F19)
- Install Karabiner
- Open Karabiner and go to Misc & Uninstall -> Open private.xml
- Copy the contents of this gist's example to the XML file and save
- In Karabiner, go to Change Keys -> Reload XML
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s_id=`curl -X POST http://127.0.0.1:4444/wd/hub/session -d '{"desiredCapabilities":{"browserName":"firefox","platform":"MAC"}}'|awk -F'"' '{print $6}'` | |
curl -X POST http://127.0.0.1:4444/wd/hub/session/$s_id/url -d '{"url":"http://www.google.com"}' | |
curl -X POST http://127.0.0.1:4444/wd/hub/session/$s_id/element -d '{"using":"id","value":"gbqfq"}' | |
curl -X POST http://127.0.0.1:4444/wd/hub/session/$s_id/element/0/value -d {"value":["selenium"]} | |
curl -X POST http://127.0.0.1:4444/wd/hub/session/$s_id/element -d '{"using":"id","value":"gbqfb"}' | |
curl -X POST http://127.0.0.1:4444/wd/hub/session/$s_id/element/1/click | |
curl -X DELETE http://127.0.0.1:4444/wd/hub/session/$s_id/window |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
display dialog "Name of the browser?" default answer "Safari" | |
set inp to text returned of result | |
tell application "System Events" | |
if inp is "Google Chrome" then | |
tell application "Google Chrome" to return URL of active tab of front window | |
else if inp is "Safari" then | |
tell application "Safari" to return URL of front document | |
else if inp is "Firefox" then | |
tell application "Firefox" to activate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <windows.h> | |
#include <gdiplus.h> | |
#include <time.h> | |
int GetEncoderClsid(const WCHAR* format, CLSID* pClsid) { | |
using namespace Gdiplus; | |
UINT num = 0; | |
UINT size = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Windows Registry Editor Version 5.00 | |
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies] | |
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\ActiveDesktop] | |
"NoChangingWallPaper"=dword:00000001 | |
"NoAddingComponents"=dword:00000001 | |
"NoClosingComponents"=dword:00000001 | |
"NoDeletingComponents"=dword:00000001 | |
"NoEditingComponents"=dword:00000001 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Admin email address | |
admin_email=admin@domain.com | |
### Setup the server to mirror | |
mirror=rsync://archive.ubuntu.com/ubuntu | |
### Log file path | |
log=/var/log/ubuntu | |
### Setup the local directory |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[core] | |
whitespace = nowarn | |
pager = less -FRSX | |
edito = vim | |
editor = vim | |
whitespace=fix,-indent-with-non-tab,trailing-space#,cr-at-eol | |
autocrlf = input | |
[user] | |
name = Prashanth | |
email = Email |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Adaptation from https://medium.com/cohealo-engineering/how-set-up-a-slack-channel-to-be-an-aws-sns-subscriber-63b4d57ad3ea | |
var https = require('https'); | |
var util = require('util'); | |
exports.handler = function(event, context) { | |
console.log(JSON.stringify(event, null, 2)); | |
console.log('From SNS:', event.Records[0].Sns.Message); | |
var postData = { | |
"channel": "#aws_playground", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Adaptation from https://medium.com/cohealo-engineering/how-set-up-a-slack-channel-to-be-an-aws-sns-subscriber-63b4d57ad3ea | |
var https = require('https'); | |
var util = require('util'); | |
exports.handler = function(event, context) { | |
console.log(JSON.stringify(event, null, 2)); | |
console.log('From SNS:', event.Records[0].Sns.Message); | |
var postData = { | |
"channel": "#aws_playground", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Argument = -h -v -i groupId:artifactId:version -c classifier -p packaging -r repository -l location -u username -P password | |
#shopt -o -s xtrace | |
# Define Nexus Configuration | |
NEXUS_BASE=http://sonatype.nexus.example.com:8081/nexus | |
REST_PATH=/service/local | |
ART_REDIR=/artifact/maven/redirect |
NewerOlder