This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // components/themeToggle.js | |
| //... | |
| <ToggleButton | |
| type="button" | |
| onClick={() => setActiveTheme(inactiveTheme)} | |
| > |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # This bootstraps installing ssh-keys to github | |
| # set colors | |
| if tput setaf 1 &> /dev/null; then | |
| tput sgr0 | |
| if [[ $(tput colors) -ge 256 ]] 2>/dev/null; then | |
| ORANGE="$(tput setaf 172)" | |
| else |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # ------------------------------------------------------------------------------------------ | |
| # May 4, 2021 Update | |
| # This is maintained here for reference, but it seems like the networksetup script | |
| # is capable of doing this, at least in Big Sur. I haven't tested this on older versions. | |
| # See https://gist.github.com/mrpnelson/c65302efed6c18300fb28c8da87bc69a#gistcomment-3731567 | |
| # for details on using the native tooling | |
| # ------------------------------------------------------------------------------------------ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # I like to start fresh with a new mac, instead of using the Migration Assistant, because of all the cruft | |
| # and useless software that may have accumulated. | |
| # | |
| # This script sets ups macs the way I like as a mostly JavaScript and Python developer. Feel free to copy | |
| # and edit it as you see fit. | |
| # | |
| # Depends on a .env.sh file that sets up aliases here: | |
| # https://gist.github.com/tuckerconnelly/2e69cbd3c6432c815e733f45c5827ad7 | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| touch ~/.zprofile | |
| COMPNAME="Titan" | |
| sudo scutil --set ComputerName "$COMPNAME" | |
| sudo scutil --set HostName "$COMPNAME" | |
| sudo scutil --set LocalHostName "$COMPNAME" | |
| sudo defaults write /Library/Preferences/SystemConfiguration/com.apple.smb.server NetBIOSName -string "$COMPNAME" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # source: https://git.abackstrom.com/appify.git/blob_plain/HEAD:/appify.sh | |
| # | |
| # appify -- convert your non-interactive shell script into a Mac OS X application | |
| # Copyright (C) 2010 Adam Backstrom | |
| # | |
| # This program is free software; you can redistribute it and/or | |
| # modify it under the terms of the GNU General Public License | |
| # as published by the Free Software Foundation; either version 2 | |
| # of the License, or (at your option) any later version. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| echo "Expanding the save panel by default" | |
| defaults write NSGlobalDomain NSNavPanelExpandedStateForSaveMode -bool true | |
| defaults write NSGlobalDomain PMPrintingExpandedStateForPrint -bool true | |
| defaults write NSGlobalDomain PMPrintingExpandedStateForPrint2 -bool true | |
| echo "Displaying ASCII control characters using caret notation in standard text views" | |
| defaults write NSGlobalDomain NSTextShowsControlCharacters -bool true | |
| echo "Disabling automatic termination of inactive apps" | |
| defaults write NSGlobalDomain NSDisableAutomaticTermination -bool true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** That's it. Thank you. */ | |
| filter: sepia(0.9) brightness(0.8); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| Appify="$(basename "$0")" | |
| if [ ! "$1" -o "$1" = "-h" -o "$1" = "--help" ]; then cat <<EOF | |
| Appify v5 for Mac OS X | |
| Creates the simplest possible Mac OS X app from a shell script. | |
| Takes a shell script as its first argument: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Inspired by https://gist.github.com/kevinelliott/7a152c556a83b322e0a8cd2df128235c | |
| ############################################################################## | |
| # Install brew and base set of packages | |
| ############################################################################## | |
| /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)" | |
| # might need to run `sudo chown -R $USER:admin /usr/local` if install fails because of permissions issue. | |
| brew update && brew upgrade |
NewerOlder