Skip to content

Instantly share code, notes, and snippets.

View kritoke's full-sized avatar

Matt kritoke

View GitHub Profile
@deepu105
deepu105 / VSCode-extensions
Created June 16, 2019 14:49
VSCode plugins I use
code --install-extension QassimFarid.ejs-language-support
code --install-extension SirTori.indenticator
code --install-extension TimonVS.ReactSnippetsStandard
code --install-extension TwentyChung.jsx
code --install-extension abusaidm.html-snippets
code --install-extension asvetliakov.move-imports
code --install-extension aws-scripting-guy.cform
code --install-extension bierner.markdown-preview-github-styles
code --install-extension ccitiriga.TSMethodCreator
code --install-extension christian-kohler.npm-intellisense
@josephan
josephan / setup_tailwind_in_phoenix.md
Last active August 8, 2023 05:50
Add Tailwind CSS to an Elixir/Phoenix Project with PurgeCSS
#!/bin/bash
# export DBUS_SESSION_BUS_ADDRESS environment variable because cron hates me
PID=$(pgrep -u USER gnome-session-b)
export DBUS_SESSION_BUS_ADDRESS=$(grep -z DBUS_SESSION_BUS_ADDRESS /proc/$PID/environ|cut -d= -f2-)
/usr/bin/gsettings set org.gnome.shell.extensions.user-theme name 'Flat-Plat'
/usr/bin/gsettings set org.gnome.desktop.interface gtk-theme 'Flat-Plat'
/usr/bin/gsettings set org.gnome.desktop.background picture-uri 'file://WALLPAPER-PATH'
/usr/bin/gsettings --schemadir ~/.local/share/gnome-shell/extensions/[email protected] set org.zzrough.gs-extensions.drop-down-terminal background-color 'rgb(69,90,100)'

Local Variable Scope, especially how local variable interact with blocks and methods

Local variables cannot be accessed in a method, but can in a block.

ex. this is not possible

greet = 'hello!'

def greeter(str)
 puts greet + str #greet is not accessible inside the method.
@mbbx6spp
mbbx6spp / 00README.adoc
Last active February 8, 2021 01:39
My ${HOME}/.nixpkgs/config.nix to setup my dev and desktop environments the way I like them :)

User env setup

Setup your user environment just the way you want with Nix.

  1. Add packageOverrides to the attrset returned by your ${HOME}/.nixpkgs/config.nix (see my example above).

  2. Then with one command you can setup your whole environment: nix-env -i desktop-mbbx6spp.

Then all you need is a simple ~/.bash_profile script like so:

@sebz
sebz / grunt-hugo-lunrjs.md
Last active June 28, 2024 18:41
hugo + gruntjs + lunrjs = <3 search
@rubencaro
rubencaro / install_elixir.md
Last active September 30, 2023 03:58
Elixir installation guide

Elixir installation guide

Version numbers should be the ones you want. Here I do it with the last ones available at the moment of writing.

The simplest way to install elixir is using your package manager. Sadly, at the time of writing only Fedora shows the intention to keep its packages up to date. There you can simply sudo dnf install erlang elixir and you are good to go.

Anyway, if you intend to work with several versions of erlang or elixir at the same time, or you are tied to a specific version, you will need to compile it yourself. Then asdf is your best friend.

@jaygilmore
jaygilmore / randomChunkRevo.php
Last active December 10, 2015 21:08
A MODX Revolution Version of Sal Sodano's RandomChunk to randomly display Chunks. Ideally used with Jason Coward's getCache.
<?php
/*
* RandomChunk
* Salvatore Sodano
* http://salscode.com
* Revolution Version 2013, Jay Gilmore aka smashingred
* [[!RandomChunk? &chunks=`chunk1, chunk2`]]
* Randomly generates a chunk from a comma separated list of chunks.
*
*/