Skip to content

Instantly share code, notes, and snippets.

View Aldiwildan77's full-sized avatar
:octocat:
Exploring

Muhammad Wildan Aldiansyah Aldiwildan77

:octocat:
Exploring
View GitHub Profile
@ruph
ruph / .vimrc
Last active July 18, 2024 14:34
vim settings
" Use vim settings, rather then vi settings (much better!)
" This must be first, because it changes other options as a side effect.
set nocompatible
set t_Co=256 " iTerm2 supports 256 color mode.
set ai " auto indenting
set history=100 " keep 100 lines of history
set ruler " show the cursor position
syntax on " syntax highlighting
filetype plugin on " use the file type plugins
@danielestevez
danielestevez / gist:2044589
Last active July 26, 2024 08:30
GIT Commit to an existing Tag
1) Create a branch with the tag
git branch {tagname}-branch {tagname}
git checkout {tagname}-branch
2) Include the fix manually if it's just a change ....
git add .
git ci -m "Fix included"
or cherry-pick the commit, whatever is easier
git cherry-pick {num_commit}
@dergachev
dergachev / README.md
Created October 10, 2012 16:49
Vagrant tutorial

Vagrant Setup

This tutorial guides you through creating your first Vagrant project.

We start with a generic Ubuntu VM, and use the Chef provisioning tool to:

  • install packages for vim, git
  • create user accounts, as specified in included JSON config files
  • install specified user dotfiles (.bashrc, .vimrc, etc) from a git repository

Afterwards, we'll see how easy it is to package our newly provisioned VM

@rcrowley
rcrowley / acknowledgment_test.go
Last active October 14, 2022 09:22
Benchmark of goroutine acknowledgment patterns
// Go encourages us to organize our code using goroutines and to use
// channels of channels to implement request-response semantics [1].
//
// I have encountered far more instances that require acknowledgment
// than fully-fledged respones so I became curious whether channels
// of channels were indeed the best implementation strategy.
//
// In summary, yes, they are. These benchmarks demonstrate that
// channels perform better than mutexes, that condition variables are
// still clumsy, and that preallocation is a huge win when and if you
@ReSTARTR
ReSTARTR / README.md
Last active March 6, 2023 23:11
ZeroMQ sample in Go and Python. (with MonitoredQueue)

Versions

  • zeromq: stable 3.2.2
  • go: 1.0.3
    • gozmq: zmq_3_x
  • python: 2.7.3
    • pyzmq: 13.0.2

Usage

@jctosta
jctosta / screen_cheatsheet.markdown
Last active July 28, 2024 08:46
Screen Cheatsheet

Screen Quick Reference

Basic

Description Command
Start a new session with session name screen -S <session_name>
List running sessions / screens screen -ls
Attach to a running session screen -x
Attach to a running session with name screen -r
@stupidbodo
stupidbodo / csv.go
Last active February 12, 2024 07:05
Golang - Read CSV/JSON from URL
package main
import (
"encoding/csv"
"fmt"
"net/http"
)
func readCSVFromUrl(url string) ([][]string, error) {
resp, err := http.Get(url)
@ryanmaclean
ryanmaclean / ubuntu_devops_workstation_setup.md
Last active June 30, 2024 14:31
Ubuntu DevOps Workstation Setup

Ubuntu for DevOps and SRE Work

sudo sed -i '/cdrom/d' /etc/apt/sources.list

I'd certainly recommend moving to keys over passwords, but for now, it'll do...

sudo apt-get install -y openssh-server
sudo cp /etc/ssh/sshd_config /etc/ssh/sshd_config.factory-defaults
@wavded
wavded / go-ci-build.sh
Last active March 1, 2023 23:30
Go Jenkins CI Script - golang
#!/bin/bash
# Go build script that runs cloc, cpd, lint, vet, test and coverage for Jenkins
#
# Outside tools include:
# gocov: go get github.com/axw/gocov
# gocov-xml: go get github.com/t-yuki/gocov-xml
# go2xunit: go get bitbucket.org/tebeka/go2xunit
# jscpd: npm i jscpd -g
# cloc: npm i cloc -g
anonymous
anonymous / print.css
Created June 22, 2016 13:53
/**
* Print Stylesheet fuer Deinewebsite.de
* @version 1.0
* @lastmodified 16.06.2016
*/
@media print {
/* Inhaltsbreite setzen, Floats und Margins aufheben */
/* Achtung: Die Klassen und IDs variieren von Theme zu Theme. Hier also eigene Klassen setzen */