Skip to content

Instantly share code, notes, and snippets.

View maxt3r's full-sized avatar

Max Al Farakh maxt3r

View GitHub Profile
@maxt3r
maxt3r / cs2.conf
Last active November 22, 2023 15:47
CS:GO config
alias "+jt" "+jump;";
alias "+ta" "-attack; -attack2";
alias "-jt" "-jump";
bind "MOUSE5" "+jt;+ta;";
alias +knife slot3;
alias -knife lastinv;
alias +netg "cl_showfps 2;
cq_netgraph 1;+showscores";
alias -netg "cl_showfps 0;cq_netgraph 0;-showscores";bind TAB "+netg";
@maxt3r
maxt3r / fulltext.cs
Last active August 28, 2017 14:05
Full-text query generator
public class FullTextUtils
{
static HashSet<string> StopWords { get; set; }
static FullTextUtils() //static constructor. init stopwords
{
try
{
using (var cn = DBUtils.GetNewOpenConnection())
{
@maxt3r
maxt3r / autoresize.ts
Created November 28, 2016 17:39
Ionic 2 ion-textarea autoresize
// An autoresize directive that works with ion-textarea in Ionic 2
// Usage example: <ion-textarea autoresize [(ngModel)]="body"></ion-textarea>
// Based on https://www.npmjs.com/package/angular2-autosize
import { Directive, HostListener, ElementRef } from "@angular/core";
@Directive({
selector: "ion-textarea[autoresize]" // Attribute selector
})
export class Autoresize {
@maxt3r
maxt3r / hgcp.sh
Created November 18, 2012 13:17
Quick commit and push with Mercurial
#Quick way to commit and push for Mercurial. Put it into your .zshrc
#No need to write -m and to put a commit message into quotes
#Example usage: hgcp commit message
hgcp() {hg commit -m "$*"; hg push}
@maxt3r
maxt3r / selectioncolor.css
Created November 30, 2011 14:59
Changing text selection color with CSS
::-moz-selection { background: #4DA400; color: #fff; text-shadow: none; }
::selection { background: #4DA400; color: #fff; text-shadow: none; }
@maxt3r
maxt3r / topten.sh
Created November 29, 2011 21:06
Top 10 most used terminal commands
history | awk '{print $2}' | sort | uniq -c | sort -rn | head -10