Skip to content

Instantly share code, notes, and snippets.

View markstachowski's full-sized avatar

Mark Stachowski markstachowski

View GitHub Profile
@jernejcic
jernejcic / .bash_profile
Last active April 1, 2023 02:08
.bash_profile file on Mac OS X
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases.
# Much of this was originally copied from:
# http://natelandau.com/my-mac-osx-bash_profile/
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
@yang-wei
yang-wei / fullscreen.css
Last active June 6, 2024 06:56
Full size background image using CSS cover in mobile devices
html {
background: url(image url) no-repeat center center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
height: 100%;
overflow: hidden;
}
@mestizo
mestizo / gist:9167834
Last active July 22, 2024 20:34
Completely disable IPv6 on OSX
#To Get List of Hardware
sudo networksetup -listallhardwareports
#To Disable IPv6 on Wifi Adapter
sudo networksetup -setv6off wi-fi
#To Disable IPv6 on Built-in Ethernet Adapter
sudo networksetup -setv6off Ethernet
@petemcw
petemcw / brew-instructions.sh
Last active July 14, 2025 23:22
Setup dnsmasq on Mac OS X
# Install `dnsmasq` and configure for *.test domains
$ brew install dnsmasq
$ vim /usr/local/etc/dnsmasq.conf
# Reload configuration and clear cache
$ sudo launchctl unload /Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist
$ sudo launchctl load /Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist
$ dscacheutil -flushcache
@DanHerbert
DanHerbert / fix-homebrew-npm.md
Last active June 8, 2025 15:03
Instructions on how to fix npm if you've installed Node through Homebrew on Mac OS X or Linuxbrew

OBSOLETE

This entire guide is based on an old version of Homebrew/Node and no longer applies. It was only ever intended to fix a specific error message which has since been fixed. I've kept it here for historical purposes, but it should no longer be used. Homebrew maintainers have fixed things and the options mentioned don't exist and won't work.

I still believe it is better to manually install npm separately since having a generic package manager maintain another package manager is a bad idea, but the instructions below don't explain how to do that.

Fixing npm On Mac OS X for Homebrew Users

Installing node through Homebrew can cause problems with npm for globally installed packages. To fix it quickly, use the solution below. An explanation is also included at the end of this document.

@danpastori
danpastori / final_html_example.html
Created March 21, 2014 21:56
Final HTML example in the tutorial
<!DOCTYPE html>
<html>
<head>
<title>Single Song Picture Tutorial</title>
<script type="text/javascript" src="../amplitude.js"></script>
<link rel="stylesheet" type="text/css" href="playlist-styles.css"/>
</head>
<div id="player">
<div id="player-art">
@ronaldsuwandi
ronaldsuwandi / config.fish
Last active July 30, 2021 07:54
My personal fish shell config for OS X. Supports git branch (fast git checks), virtualenv (if installed) and Kubernetes current context
function ls --description 'List contents of directory'
command ls -lFG $argv
end
function subl --description 'Launches sublime text in a new window'
command subl -n $argv
end
function code --description 'Launches visual code studio in a new window'
command code -n $argv
@magicznyleszek
magicznyleszek / google-search-variables.md
Last active October 30, 2023 22:30
Google Search Variables

Google Search Variables

If you forgot about any of these terms, go to the Advanced Search page and be happy.

Words-related

Either/or -- search for pages containing any of phrases

@dcorns
dcorns / FedoraWebDevSetup
Last active March 13, 2023 14:01
One way to setup Fedora distro for Web Development
Fedora Setup Notes
1) If you did not make yourself an administrator during the install, Add yourself to etc/sudoers using the command visudo (allows user to authenticate own account for operations requiring root).
a) su, enter root password when prompted
b) visudo (use vi for sudo to edit the file following instructions in the file; either add self as a sudo user or enable a group for sudo user and add your self to that group using user group commands)
c) ctrl-D (exit root access)
d) logout and log back in or restart
e) Now you should be able to respond to any prompt requiring root with your own login credentials and be able to run commands using sudo with your own credentials.
2) Google Chrome Setup