Skip to content

Instantly share code, notes, and snippets.

@az7arul
az7arul / list-constraints.sql
Created March 16, 2018 09:16 — forked from PickledDragon/list-constraints.sql
Postgres list all constraints
SELECT
tc.constraint_name, tc.table_name, kcu.column_name,
ccu.table_name AS foreign_table_name,
ccu.column_name AS foreign_column_name
FROM
information_schema.table_constraints AS tc
JOIN information_schema.key_column_usage AS kcu
ON tc.constraint_name = kcu.constraint_name
JOIN information_schema.constraint_column_usage AS ccu
ON ccu.constraint_name = tc.constraint_name
sv_cheats 1
sv_infinite_ammo 2
ammo_grenade_limit_total 5
mp_warmup_end
mp_freezetime 0
mp_roundtime 60
mp_roundtime_defuse 60
sv_grenade_trajectory 1
sv_grenade_trajectory_time 10
sv_showimpacts 0
unbindall
bind "1" "slot1"
bind "2" "slot2"
bind "3" "slot3"
bind "4" "slot4"
bind "5" "slot5"
bind "9" "slot9"
bind "a" "+moveleft"
bind "b" "buymenu"
bind "c" "radio3"
# -*- mode: ruby -*-
# vi: set ft=ruby :
# All Vagrant configuration is done below. The "2" in Vagrant.configure
# configures the configuration version (we support older styles for
# backwards compatibility). Please don't change it unless you know what
# you're doing.
Vagrant.configure(2) do |config|
config.vm.box = "ubuntu-12"
@az7arul
az7arul / -
Created September 10, 2014 05:59
<iframe src='data:text/html,<blockquote class="twitter-tweet" lang="en"><p>Only possible in <a href="https://twitter.com/hashtag/bd?src=hash">#bd</a> a fucking retard interrupts tech conference and he happens to be a minister of this sector</p>&mdash; Md. Azharul Islam (@az7arul) <a href="https://twitter.com/az7arul/status/474766166330580992">June 6, 2014</a></blockquote>
<script async src="http://platform.twitter.com/widgets.js" charset="utf-8"></script>'></iframe>
fn main () {
let (tx, rx) = channel();
spawn(proc() {
tx.send(10i);
});
println!("{}", rx.recv());
}
# bash/zsh completion support for core Git.
#
# Copyright (C) 2006,2007 Shawn O. Pearce <spearce@spearce.org>
# Conceptually based on gitcompletion (http://gitweb.hawaga.org.uk/).
# Distributed under the GNU General Public License, version 2.0.
#
# The contained completion routines provide support for completing:
#
# *) local and remote branch names
# *) local and remote tag names
#!/bin/bash
#
# DESCRIPTION:
#
# Set the bash prompt according to:
# * the active virtualenv
# * the branch/status of the current git repository
# * the return value of the previous command
# * the fact you just came from Windows and are used to having newlines in
# your prompts.
@az7arul
az7arul / Query.js
Last active August 29, 2015 13:58
Mongoose default paranoia
function Query(conditions, options, model, collection) {
// this stuff is for dealing with custom queries created by #toConstructor
if (!this._mongooseOptions) {
this._mongooseOptions = options || {};
} else {
// this is the case where we have a CustomQuery, we need to check if we got
// options passed in, and if we did, merge them in
if (options) {
var keys = Object.keys(options);
public void changetoOtherView(View view) {
Intent intent = new Intent(this, DisplayMessageActivity.class);
String url = "http://www.google.com";
Log.i("url", url);
AsyncHttpClient client = new AsyncHttpClient();
client.get(url, new AsyncHttpResponseHandler() {