Skip to content

Instantly share code, notes, and snippets.

View nguyenlamlll's full-sized avatar
🚀
Working!

Lam Le nguyenlamlll

🚀
Working!
View GitHub Profile
@vielhuber
vielhuber / script.sh
Last active May 14, 2025 23:58
PostgreSQL: Backup and restore export import pg_dump with password on command line #sql
# best practice: linux
nano ~/.pgpass
*:5432:*:username:password
chmod 0600 ~/.pgpass
# best practice: windows
edit %APPDATA%\postgresql\pgpass.conf
*:5432:*:username:password
# linux
@jmcgeheeiv
jmcgeheeiv / download-latest-jenkins-artifact.py
Last active November 8, 2023 06:36 — forked from supertom/fetch_debs_from_jenkins.py
Download the latest successful build artifacts from Jenkins using Python 3
#!/usr/bin/env python3
# Download the latest successful build artifacts from Jenkins using Python 3
# John McGehee 1/25/2016
#
# Based on the Python 2 version by supertom: https://gist.github.com/supertom/2759847
import argparse
import codecs
import io
import json
@DashW
DashW / ScreenRecorder.cs
Last active April 28, 2025 07:38
ScreenRecorder - High Performance Unity Video Capture Script
using UnityEngine;
using System;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using System.Threading;
class BitmapEncoder
{
public static void WriteBitmap(Stream stream, int width, int height, byte[] imageData)
@cpietsch
cpietsch / README.md
Last active May 22, 2025 12:36
d3.js map with markers

Easy example on how to put marker on a d3.js map.

You got 2 options:

  • using d3.geo.path() which does all the work for you
  • using svg circles and translating them via projection(d.geometry.coordinates)
@iamfaisal
iamfaisal / Web.config
Created August 9, 2015 11:38
Web.config for Codeigniter 3.0
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="Rule" stopProcessing="true">
<match url="^(.*)$" ignoreCase="false" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="false" negate="true" />
@wmandai
wmandai / Codeigniter IIS web.config
Last active August 11, 2023 06:24
IIS web.config for codeigniter
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="Index">
<match url="^(.*)$" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
@jpluimers
jpluimers / get-msbuildExe-path.bat
Last active March 2, 2019 22:26
Get the path to the most recent msbuild.exe from the registry.
@echo off
:: http://stackoverflow.com/questions/328017/path-to-msbuild
:: http://www.csharp411.com/where-to-find-msbuild-exe/
:: http://timrayburn.net/blog/visual-studio-2013-and-msbuild/
:: http://blogs.msdn.com/b/visualstudio/archive/2013/07/24/msbuild-is-now-part-of-visual-studio.aspx
setlocal
:vswhereModernTry
:: https://github.com/Microsoft/vswhere/wiki/Find-MSBuild
:: Normal output example of `vswhere -legacy -latest -property installationPath` has no trailing back-slash:
@jdarling
jdarling / data.json
Last active March 24, 2025 21:35
D3 MindMap
{
"name": "Root",
"children": [
{
"name": "Branch 1",
"children": [
{"name": "Leaf 3"},
{"name": "Leaf 4"}
]
},
@w25r
w25r / .gitignore
Last active August 7, 2022 19:42
Basic .gitignore for gradle, including Eclipse and Intellij settings
#Gradle
.gradle/
build/
# Eclipse
.classpath
.project
.settings/
bin/
@hubgit
hubgit / README.md
Last active May 12, 2025 09:45
A5 printed card with HTML + CSS
  1. Clone this Gist.
  2. For card sizes other than A5, edit the size value in @page, and the height and width properties of body.
  3. Add contents to each face. The simplest approach is to add an image called front.png of the same dimensions as the card.
  4. Generate a PDF from the HTML + CSS. If using Prince, it's as simple as prince index.html card.pdf.
  5. Take the PDF to a printer, and ask them to print as many copies as you need.