Skip to content

Instantly share code, notes, and snippets.

View CharlieEtienne's full-sized avatar
🖖
Hi GitHub!

Charlie Etienne CharlieEtienne

🖖
Hi GitHub!
View GitHub Profile
@stenuto
stenuto / timelapse.sh
Created June 18, 2024 20:56
Timelapse script
#!/bin/bash
# Check if interval argument is provided
if [ -z "$1" ]; then
echo "Usage: $0 -int <interval_in_seconds>"
exit 1
fi
# Extract the interval value
interval=$2
@tarecord
tarecord / .distignore
Created May 29, 2023 20:14
A basic .distignore for a Wordpress plugin using dist-archive WP-CLI package
# A set of files you probably don't want in your WordPress.org distribution
.deploy
.distignore
.DS_Store
.editorconfig
.git
.github
.gitignore
.gitmodules
*.sql
@jchandra74
jchandra74 / PowerShell Customization.md
Last active June 3, 2024 21:32
PowerShell, Cmder / ConEmu, Posh-Git, Oh-My-Posh, Powerline Customization

Pimping Up Your PowerShell & Cmder with Posh-Git, Oh-My-Posh, & Powerline Fonts

Backstory (TLDR)

I work as a full-stack developer at work. We are a Windows & Azure shop, so we are using Windows as our development platform, hence this customization.

For my console needs, I am using Cmder which is based on ConEmu with PowerShell as my shell of choice.

Yes, yes, I know nowadays you can use the Linux subsystem on Windows 10 which allow you to run Ubuntu on Windows. If you are looking for customization of the Ubuntu bash shell, check out this article by Scott Hanselman.

@olmokramer
olmokramer / css-color-regex
Last active December 9, 2023 12:52
Regex for CSS colors: hex, rgb(a), hsl(a)
/(#([0-9a-f]{3}){1,2}|(rgba|hsla)\(\d{1,3}%?(,\s?\d{1,3}%?){2},\s?(1|0?\.\d+)\)|(rgb|hsl)\(\d{1,3}%?(,\s?\d{1,3}%?\)){2})/i
@tripflex
tripflex / array_column_recursive.php
Last active June 17, 2021 13:07
PHP customized array_column function for recursion, named array_column_recursive
<?php
if ( ! function_exists( 'array_column_recursive' ) ) {
/**
* Returns the values recursively from columns of the input array, identified by
* the $columnKey.
*
* Optionally, you may provide an $indexKey to index the values in the returned
* array by the values from the $indexKey column in the input array.
*
* @param array $input A multi-dimensional array (record set) from which to pull