Skip to content

Instantly share code, notes, and snippets.

View rahulvramesh's full-sized avatar
💻
🚊

Rahul V Ramesh rahulvramesh

💻
🚊
View GitHub Profile
@rahulvramesh
rahulvramesh / 1_simple.go
Created February 4, 2018 10:09 — forked from sosedoff/1_simple.go
Golang Custom Struct Tags Example
package main
import (
"fmt"
"reflect"
)
// Name of the struct tag used in examples
const tagName = "validate"
@rahulvramesh
rahulvramesh / Running Jenkins From Terminal
Last active April 16, 2018 10:52
Running Jenkins From Terminal
Pre Requirements
1, Jenkins Server (We assume as http://ci.jenkins.io:8080)
@rahulvramesh
rahulvramesh / main.go
Created April 19, 2018 08:00
PDF Base64 Decoding In Golang
package main
import (
"encoding/base64"
//"io"
"os"
)
var b64 = `JVBERi0xLjQKJdPr6eEKMSAwIG9iago8PC9DcmVhdG9yIChNb3ppbGxhLzUuMCBcKE1hY2ludG9z
aDsgSW50ZWwgTWFjIE9TIFggMTBfMTNfM1wpIEFwcGxlV2ViS2l0LzUzNy4zNiBcKEtIVE1MLCBs
@rahulvramesh
rahulvramesh / Vagrantfile
Last active May 15, 2018 09:28
go-vagrant-vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.vm.box = "ubuntu/trusty64"
# set the hostname
config.vm.hostname = "mylocal.dev"
#set the shared folder
@rahulvramesh
rahulvramesh / install.sh
Created May 15, 2018 09:29
go-vagrant-install
#!/bin/bash
# This is the entry point for configuring the system.
#####################################################
#install basic tools
sudo DEBIAN_FRONTEND=noninteractive apt-get -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confnew" install git
#get golang 1.9.1
curl -O https://storage.googleapis.com/golang/go1.9.1.linux-amd64.tar.gz
@rahulvramesh
rahulvramesh / sketch.sh
Created May 20, 2018 08:27
shell script for sketch app hack
#!/bin/bash
date 0102030405
open /Applications/Sketch.app
ntpdate -u time.apple.com
@rahulvramesh
rahulvramesh / Dockerfile
Created June 11, 2018 10:05 — forked from RinatMullayanov/Dockerfile
Ubuntu Node.js Dockerfile
#
# Ubuntu Node.js Dockerfile
#
# https://github.com/dockerfile/ubuntu/blob/master/Dockerfile
# https://docs.docker.com/examples/nodejs_web_app/
#
# Pull base image.
FROM ubuntu:14.04
SELECT l.*,a.*
FROM pg_locks l
JOIN pg_stat_activity a USING (pid)
WHERE NOT granted;
sELECT pg_terminate_backend(31909);
sELECT pg_terminate_backend(754);
UPDATE "bookings" SET "status_id" = 203 WHERE (bookings.id = 997 )
select txid_current();
Name: Flash
Serial: eNrzzU/OLi0odswsqnHLSSzOqDGoca7JKCkpsNLXLy8v1ytJTczVLUotKNFLzs8FAJHYETc=
if anyone wants to thank ETH: 0x527c2aB55b744D6167dc981576318af96ed26676
Thank you!
@rahulvramesh
rahulvramesh / install.sh
Last active April 6, 2019 03:31 — forked from enricobacis/install.sh
openstack installation on CentOS 7
#!/bin/bash
export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
#read config
ifconfig
read -p "Enter your external interface: " EXT_INTER
set -x # enable echo