Skip to content

Instantly share code, notes, and snippets.

Ashhar Hasan hashhar

Block or report user

Report or block hashhar

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
hashhar /
Last active May 16, 2019
Tombstone effects on KStream, KTable and reduce


$ kafkacat -P -b -t input -K : -Z
hashhar / pwned-interactive.rb
Created Mar 12, 2019 — forked from schmich/pwned-interactive.rb
Check if a password has been pwned with the Pwned Passwords V2 API
View pwned-interactive.rb
# Check a single password interactively.
# Usage: ruby pwned-interactive.rb
require 'io/console'
require 'open-uri'
require 'digest'
puts "The 5-character prefix of the password's SHA-1 hash will be sent."
puts "For details, see"
print 'Password (hidden): '
hashhar / .inputrc
Created Oct 4, 2018
Inputrc for better readline
View .inputrc
# Make Tab autocomplete regardless of filename case
set completion-ignore-case on
# List all matches in case multiple possible completions are possible
set show-all-if-ambiguous on
# Use the text that has already been typed as the prefix for searching through
# commands (i.e. more intelligent Up/Down behavior)
"\e[B": history-search-forward
"\e[A": history-search-backward
View tab-center-redux.css
/* Hide the New Tab button */
#newtab {
display: none;
/* Remove extra padding and margins from Search tabs field */
#searchbox {
padding: 0px;
margin: -2px;
hashhar / example.php
Created Aug 25, 2017
Test case for RainbowParentheses.vim
View example.php
* Copyright 2011 Facebook, 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
hashhar /
Last active Aug 30, 2017
MPD Status in i3status
i3status | while :
read line
printf -v mpd_song "%q" "$(mpc current -f "[[%albumartist%|%artist% - ]%title%]")"
# printf -v sets the variable to '' in case of empty assignment
if [[ "$mpd_song" == "''" ]]; then
printf -v mpd_song "%q" "$(basename "$(mpc current -f "%file%")")"
hashhar / _aurvote
Last active Jul 4, 2017
Bash Completion Scripts
View _aurvote
# Written: Ashhar Hasan (hashhar_dev at outlook dot com) on 13 April 2017
# If cache file is older than a week or doesn't exist yet, update it.
local last_update=1
[ -e "${_cache_file}" ] && last_update=$(stat -c %Y "${_cache_file}")
# Compare the epoch times of existing file and current date.
hashhar / firefly.1611290733
Created Apr 12, 2017
Firefly (TV series) fortune cookie file
View firefly.1611290733
See also:Serenity (film)
"The Ballad of Serenity" (Theme song) written by Joss Whedon
Mal: We have done the impossible, and that makes us mighty.
-- Firefly (TV series) - None
Bendis: We're gonna die.
Mal: We're not gonna die. We can't die, Bendis. You know why? Because we are so... very... pretty. We are just too pretty for God to let us die. Huh? Look at that chiseled jaw!
hashhar / 10-powerline-symbols.conf
Created Apr 1, 2017
Fontconfig powerline fallback
View 10-powerline-symbols.conf
# This file goes in $HOME/.config/fontconfig/conf.d/
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
hashhar /
Created Mar 12, 2017 — forked from PurpleBooth/
A template to make good

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.


You can’t perform that action at this time.