Skip to content

Instantly share code, notes, and snippets.

View huseyin's full-sized avatar

Hüseyin Tekinaslan huseyin

View GitHub Profile
#!/bin/bash
set -euo pipefail
if command -v nc >/dev/null; then
echo >&2 "Could not find a working netcat in PATH"
echo >&2 "Please install your operating system's 'netcat' or 'nc' package"
fi
echo "$@" | nc -U ${INSPEQTOR_SOCK:-/var/run/inspeqtor.sock}

Keybase proof

I hereby claim:

  • I am huseyin on github.
  • I am huseyin (https://keybase.io/huseyin) on keybase.
  • I have a public key whose fingerprint is 1839 F2CF 1CE2 7ED2 7F82 3E4E E9FF 5797 52FD 48FB

To claim this, I am signing this object:

@huseyin
huseyin / setup.sh
Last active July 10, 2020 19:20
Vagrant completion for Zsh
#!/bin/bash
set -e
# Get bash completion script
sudo -- sh -c 'wget -qO- https://gist.githubusercontent.com/huseyin/d2479f069d304ec482a1db96652222f2/raw/3d1a7d8032fd1ddd813a2509e6d9b46ee1f9c870/vagrant >/etc/bash_completion.d/vagrant'
# Setup Zsh environment
mkdir -p ~/.config/zsh/completion
cat <<-EOF >>~/.zshrc
issuer: http://10.0.3.81:5556/dex
storage:
type: sqlite3
config:
file: dex.db
web:
http: 10.0.3.81:5556

LDAP

  • Paketleri kur

      apt-get -y install --no-install-recommends \
      	slapd \
      	ldap-utils \
      	ca-certificates
    
@huseyin
huseyin / ignore
Created April 7, 2017 23:51 — forked from roktas/ignore
Genel gitignore dosyası (~/.config/git/ignore)
.\#*
*~
\#*
*.bak
.*.d
*.orig
*.rej
*.sw
.*.sw[a-z]
*.swp
@huseyin
huseyin / config
Created April 7, 2017 23:51 — forked from roktas/config
Genel git config dosyası (~/.config/git/config)
[alias]
a = add
ap = add --patch
b = branch
c = commit
co = checkout
d = diff
f = fetch
la = log --graph --decorate --pretty=oneline --abbrev-commit --all
l = log --pretty=format:'%Cred%h%Creset - %<|(60)%C(bold)%s%Creset %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
#!/bin/sh
#
# Fork depolarda master dalında değişiklik yapmayı engelle.
if [ "$(git rev-parse --abbrev-ref HEAD)" = master ]; then
if git config remote.upstream.url >/dev/null; then
cat >&2 <<-EOF
Üst geliştirici depo referansı "upstream" belirlendi.
Alt geliştirici olarak çalıştığınız depolarda "master" dalında
#compdef scripts
#autoload
declare base_command
base_command=`SCRIPTS=scripts scripts help 2>/dev/null`
declare -A task_list
_tasks() {
_describe -t commands 'commands' task_list && return 0
@huseyin
huseyin / TODO.md
Last active January 9, 2017 20:21
  • a task list item
  • list syntax required
  • normal formatting, @mentions, #1234 refs
  • incomplete
  • completed