Skip to content

Instantly share code, notes, and snippets.

View evanhutomo's full-sized avatar
🐢
be like snapping turtle, they have armor to hide, jaw to attack

Evan Hutomo evanhutomo

🐢
be like snapping turtle, they have armor to hide, jaw to attack
  • Japan - Indonesia
View GitHub Profile
# Hello, and welcome to makefile basics.
#
# You will learn why `make` is so great, and why, despite its "weird" syntax,
# it is actually a highly expressive, efficient, and powerful way to build
# programs.
#
# Once you're done here, go to
# http://www.gnu.org/software/make/manual/make.html
# to learn SOOOO much more.
@max-mapper
max-mapper / 0.md
Last active February 25, 2024 12:24
JS hoisting by example

JavaScript function hoisting by example

Below are many examples of function hoisting behavior in JavaScript. Ones marked as works successfuly print 'hi!' without errors.

To play around with these examples (recommended) clone them with git and execute them with e.g. node a.js

Notes on hoisting

(I may be using incorrect terms below, please forgive me)

@cebe
cebe / BaseController.php
Created October 25, 2014 19:41
Yii2 API Auth with username and password
<?php
/**
*
*
* @author Carsten Brandt <mail@cebe.cc>
*/
namespace api\components;
use common\models\ApiSystem;
@Kartones
Kartones / postgres-cheatsheet.md
Last active April 25, 2024 16:50
PostgreSQL command line cheatsheet

PSQL

Magic words:

psql -U postgres

Some interesting flags (to see all, use -h or --help depending on your psql version):

  • -E: will describe the underlaying queries of the \ commands (cool for learning!)
  • -l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)

THIS DOCUMENT

IS OUT OF

DATE

C++ Coding Standards Part 0: Automated Code Analysis

Automated analysis is the main advantage to working with a modern statically typed compiled language like C++. Code analysis tools can inform us when we have implemented an operator overload with a non-canonical form, when we should have made a method const, or when the scope of a variable can be reduced.

@resarahadian
resarahadian / ClButtonTransparant.java
Created December 23, 2013 08:06
Membuat ComboBox Transparan
import java.awt.Color;
import java.awt.GradientPaint;
import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.RenderingHints;
import java.awt.Shape;
import java.awt.geom.RoundRectangle2D;
import javax.swing.*;
@SuppressWarnings("serial")
@thomd
thomd / LC_COLORS.md
Last active April 20, 2024 13:26
LSCOLORS & LS_COLORS

alternatively use: http://geoff.greer.fm/lscolors/

LSCOLORS

The value of this variable describes what color to use for which attribute when colors are enabled with CLICOLOR. This string is a concatenation of pairs of the format fb, where f is the foreground color and b is the background color.

The color designators are as follows:

a black

@buhman
buhman / 00 wpa_cli passphrase network
Last active March 8, 2023 21:51
all wpa_cli ommands can be tab-completed
localhost ~ # cat <<EOF> /etc/wpa_supplicant.conf
ctrl_interface=DIR=/run/wpa_supplicant GROUP=wheel
update_config=1
EOF
localhost ~ # wpa_supplicant -iwlp1s0 -Dnl80211 -c/etc/wpa_supplicant.conf -B
Successfully initialized wpa_supplicant
localhost ~ # wpa_cli
wpa_cli v2.0
Copyright (c) 2004-2012, Jouni Malinen <j@w1.fi> and contributors
@hofmannsven
hofmannsven / README.md
Last active April 19, 2024 13:17
Git CLI Cheatsheet