Skip to content

Instantly share code, notes, and snippets.

🚩
KubeCon mode, expect no reviews until 5/25

Ahmet Alp Balkan ahmetb

Block or report user

Report or block ahmetb

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@ahmetb
ahmetb / gcrgc.sh
Last active May 19, 2019
Script to clean up Google Container Registry images pushed before a particular date
View gcrgc.sh
#!/bin/bash
# Copyright © 2017 Google Inc.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
@ahmetb
ahmetb / gcpauth.go
Created May 22, 2018
Authenticating to GKE cluster with client-go, IAM service account and a Google auth plugin written from scratch
View gcpauth.go
package main
import (
"context"
"fmt"
"log"
"net/http"
"golang.org/x/oauth2"
"golang.org/x/oauth2/google"
@ahmetb
ahmetb / _README.md
Created May 27, 2018
BSD grep segmentation fault
View _README.md

I'm getting garbage characters on my screen and eventually segmentation fault from BSD grep "2.5.1-FreeBSD".

Repro

Download attached files and run:

/usr/bin/grep -E --color -f dirs_pattern.txt rp_dirs_used_in_deps.txt
@ahmetb
ahmetb / domains
Created Aug 26, 2012
List of gov.tr domain names I discovered (bulabildigim kadariyla bir gov.tr alan adlari listesi)
View domains
3158 GOV.TR domain names
http://ahmetalpbalkan.com/blog/gov-tr-alan-adlari-listesi/
==================================
100yilyy.gov.tr
19mayis.gov.tr
28kontrollab.gov.tr
360sakarya.gov.tr
80yilrehabilitasyon.gov.tr
9fi.gov.tr
@ahmetb
ahmetb / tmux.md
Created Dec 18, 2017 — forked from andreyvit/tmux.md
tmux cheatsheet
View tmux.md

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

# remap prefix to Control + a
View keybase.md

Keybase proof

I hereby claim:

  • I am ahmetb on github.
  • I am alp (https://keybase.io/alp) on keybase.
  • I have a public key ASB3Us2SJzEmVMqSFuc4nHcOh1xbv3QZfwp0Izayulo8vgo

To claim this, I am signing this object:

View keybase.md

Keybase proof

I hereby claim:

  • I am ahmetalpbalkan on github.
  • I am alp (https://keybase.io/alp) on keybase.
  • I have a public key whose fingerprint is BF91 C773 DD1E 2E87 AFE9 616F F84A 66B2 CBC2 9F60

To claim this, I am signing this object:

@ahmetb
ahmetb / tr.yml
Last active Dec 21, 2015 — forked from soffes/en.yml
roon.io Turkish strings
View tr.yml
tr:
viewer:
comment_on_twitter: "Twitter'da Yorum Yaz"
older: 'Daha Eskiler'
newer: 'Daha Yeniler'
feed: 'Feed'
share: 'Paylaş'
next_post: 'Sonraki Yazı'
previous_post: 'Önceki Yazı'
no_posts: 'Henüz bir yazı yazılmamış.'
@ahmetb
ahmetb / quora hack
Created Jul 13, 2013
clicks "Ask To Answer" Load More link a lot of times and finds people "Free to Ask" and clicks that button as well. I use that to get some initial free traction on my Quora questions.
View quora hack
var PAGE_LOAD_INTERVAL = 8000;
var TOTAL_PAGES = 30;
var VOTING_INTERVAL = 10*1000;
var k = 0;
var l = setInterval(function(){
$('.pager_next_link').trigger('click');
console.log('Loaded page ' + (++k));
}, PAGE_LOAD_INTERVAL);
@ahmetb
ahmetb / sloc.sh
Created Feb 17, 2013
Quick SLoC counter in CLI
View sloc.sh
# Counts source lines of code in current directory. Replace *.java with your source extension.
# (ignores empty lines)
find . -type f -name '*.java' -exec cat {} \; | sed '/^\s*$/d' | wc -l
# to ignore comments (in languages where comments start with #)
find . -type f -name '*.java' -exec cat {} \; | sed '/^\s*#/d;/^\s*$/d' | wc -l
You can’t perform that action at this time.