diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index 8e591aa62..d63bf12b3 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1,3 +1,4 @@ # These are supported funding model platforms github: driesvints +custom: ["https://www.paypal.me/driesvints"] diff --git a/.gitignore_global b/.gitignore_global index 40e13fc92..6e1e8abed 100644 --- a/.gitignore_global +++ b/.gitignore_global @@ -38,3 +38,9 @@ Thumbs.db .idea/ .vscode .vagrant/ + +# AI # +###################### +.claude/settings.local.json + +polyscope.local.json \ No newline at end of file diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 000000000..21becb578 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "plugins/artisan"] + path = plugins/artisan + url = git@github.com:jessarcher/zsh-artisan.git diff --git a/.macos b/.macos index 073da15a9..3883c5c38 100644 --- a/.macos +++ b/.macos @@ -815,13 +815,6 @@ defaults -currentHost write com.apple.ImageCapture disableHotPlug -bool true defaults write com.google.Chrome PMPrintingExpandedStateForPrint2 -bool true defaults write com.google.Chrome.canary PMPrintingExpandedStateForPrint2 -bool true -############################################################################### -# GPGMail 2 # -############################################################################### - -# Disable signing emails by default -# defaults write ~/Library/Preferences/org.gpgtools.gpgmail SignNewEmailsByDefault -bool false - ############################################################################### # Opera & Opera Developer # ############################################################################### diff --git a/.zshrc b/.zshrc index a6e56c3b6..dc0ddbbc6 100644 --- a/.zshrc +++ b/.zshrc @@ -5,10 +5,7 @@ export DOTFILES=$HOME/.dotfiles # export PATH=$HOME/bin:/usr/local/bin:$PATH # Path to your oh-my-zsh installation. -export ZSH=$HOME/.oh-my-zsh - -# Enable completions -autoload -Uz compinit && compinit +export ZSH="$HOME/.oh-my-zsh" # Minimal - Theme Settings export MNML_INSERT_CHAR="$" @@ -18,12 +15,12 @@ export MNML_RPROMPT=('mnml_cwd 20') # Set name of the theme to load --- if set to "random", it will # load a random theme each time oh-my-zsh is loaded, in which case, # to know which specific one was loaded, run: echo $RANDOM_THEME -# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes +# See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes ZSH_THEME="minimal" # Set list of themes to pick from when loading at random # Setting this variable when ZSH_THEME=random will cause zsh to load -# a theme from this variable instead of looking in ~/.oh-my-zsh/themes/ +# a theme from this variable instead of looking in $ZSH/themes/ # If set to an empty array, this variable will have no effect. # ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" ) @@ -34,17 +31,16 @@ ZSH_THEME="minimal" # Case-sensitive completion must be off. _ and - will be interchangeable. # HYPHEN_INSENSITIVE="true" -# Uncomment the following line to disable bi-weekly auto-update checks. -# DISABLE_AUTO_UPDATE="true" - -# Uncomment the following line to automatically update without prompting. -# DISABLE_UPDATE_PROMPT="true" +# Uncomment one of the following lines to change the auto-update behavior +# zstyle ':omz:update' mode disabled # disable automatic updates +# zstyle ':omz:update' mode auto # update automatically without asking +# zstyle ':omz:update' mode reminder # just remind me to update when it's time # Uncomment the following line to change how often to auto-update (in days). -# export UPDATE_ZSH_DAYS=13 +# zstyle ':omz:update' frequency 13 # Uncomment the following line if pasting URLs and other text is messed up. -# DISABLE_MAGIC_FUNCTIONS=true +# DISABLE_MAGIC_FUNCTIONS="true" # Uncomment the following line to disable colors in ls. # DISABLE_LS_COLORS="true" @@ -56,6 +52,9 @@ ZSH_THEME="minimal" # ENABLE_CORRECTION="true" # Uncomment the following line to display red dots whilst waiting for completion. +# You can also set it to another string to have that shown instead of the default red dots. +# e.g. COMPLETION_WAITING_DOTS="%F{yellow}waiting...%f" +# Caution: this setting can cause issues with multiline prompts in zsh < 5.7.1 (see #5765) # COMPLETION_WAITING_DOTS="true" # Uncomment the following line if you want to disable marking untracked files @@ -75,11 +74,11 @@ HIST_STAMPS="dd/mm/yyyy" ZSH_CUSTOM=$DOTFILES # Which plugins would you like to load? -# Standard plugins can be found in ~/.oh-my-zsh/plugins/* -# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ +# Standard plugins can be found in $ZSH/plugins/ +# Custom plugins may be added to $ZSH_CUSTOM/plugins/ # Example format: plugins=(rails git textmate ruby lighthouse) # Add wisely, as too many plugins slow down shell startup. -plugins=(git) +plugins=(artisan git) source $ZSH/oh-my-zsh.sh @@ -109,3 +108,39 @@ export LANG=en_US.UTF-8 # Example aliases # alias zshconfig="mate ~/.zshrc" # alias ohmyzsh="mate ~/.oh-my-zsh" + +# Herd injected PHP binary. +export PHP_INI_SCAN_DIR="$HOME/Library/Application Support/Herd/config/php/":$PHP_INI_SCAN_DIR + +# Herd injected NVM configuration +export NVM_DIR="$HOME/Library/Application Support/Herd/config/nvm" + +[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm + +[[ -f "/Applications/Herd.app/Contents/Resources/config/shell/zshrc.zsh" ]] && builtin source "/Applications/Herd.app/Contents/Resources/config/shell/zshrc.zsh" + +# Herd injected PHP 7.4 configuration. +export HERD_PHP_74_INI_SCAN_DIR="/Users/driesvints/Library/Application Support/Herd/config/php/74/" + +# Herd injected PHP 8.3 configuration. +export HERD_PHP_83_INI_SCAN_DIR="/Users/driesvints/Library/Application Support/Herd/config/php/83/" + +# Herd injected PHP 8.2 configuration. +export HERD_PHP_82_INI_SCAN_DIR="/Users/driesvints/Library/Application Support/Herd/config/php/82/" + +# Herd injected PHP 8.1 configuration. +export HERD_PHP_81_INI_SCAN_DIR="/Users/driesvints/Library/Application Support/Herd/config/php/81/" + +# Herd injected PHP 8.0 configuration. +export HERD_PHP_80_INI_SCAN_DIR="/Users/driesvints/Library/Application Support/Herd/config/php/80/" + +# Herd injected PHP binary. +export PATH="/Users/driesvints/Library/Application Support/Herd/bin/":$PATH + + +# Herd injected PHP 8.4 configuration. +export HERD_PHP_84_INI_SCAN_DIR="/Users/driesvints/Library/Application Support/Herd/config/php/84/" + + +# Herd injected PHP 8.5 configuration. +export HERD_PHP_85_INI_SCAN_DIR="/Users/driesvints/Library/Application Support/Herd/config/php/85/" diff --git a/Brewfile b/Brewfile index 15ea37330..4c6b471a7 100644 --- a/Brewfile +++ b/Brewfile @@ -1,29 +1,26 @@ # Taps -tap 'homebrew/cask' tap 'homebrew/cask-fonts' tap 'homebrew/cask-versions' -tap 'homebrew/bundle' -tap 'nicoverbruggen/homebrew-cask' +tap 'stripe/stripe-cli' # Binaries brew 'awscli' brew 'bash' # Latest Bash version +brew 'bat' # Used for spatie/visit brew 'coreutils' # Those that come with macOS are outdated +brew 'entireio/tap/entire' brew 'ffmpeg' brew 'gh' brew 'git' -brew 'gnupg' brew 'grep' brew 'httpie' -brew 'hub' +brew 'jq' # Used for spatie/visit brew 'mackup' brew 'mas' # Mac App Store manager brew 'pkg-config' # https://github.com/driesvints/dotfiles/issues/20 brew 'stripe/stripe-cli/stripe' -brew 'svn' -brew 'trash' # Manage the Trash bin -brew 'tree' # List directories in a tree structure -brew 'zlib' # Needed for Memcached +brew 'stripe/stripe-mock/stripe-mock' +brew 'svn' # Needed to install fonts # Spatie Medialibrary brew 'jpegoptim' @@ -33,53 +30,43 @@ brew 'svgo' brew 'gifsicle' # Development -brew 'php' -brew 'php@7.4' -brew 'php@7.3' -brew 'composer' brew 'imagemagick' -brew 'libmemcached' -brew 'meilisearch' -brew 'memcached' -brew 'mysql' -brew 'nginx' -brew 'node' -brew 'redis' brew 'yarn' # Apps cask '1password' -cask '1password-cli' -cask 'aerial' +brew '1password-cli' cask 'caffeine' -cask 'dbngin' +cask 'claude' +cask 'claude-code' +cask 'codex' +cask 'copilot-cli' +cask 'cursor' +cask 'cursor-cli' +cask 'cyberduck' cask 'discord' cask 'docker' cask 'figma' cask 'firefox' cask 'github' -cask 'google-backup-and-sync' cask 'google-chrome' -cask 'gpg-suite' +cask 'helo' +cask 'herd' +cask 'httpie' cask 'imageoptim' -cask 'insomnia' +cask 'loom' cask 'pastebot' -cask 'phpmon' -cask 'phpstorm' -cask 'ray' -cask 'screenflow' -cask 'signal' +cask 'reflex' +cask 'screen-studio' cask 'slack' cask 'tableplus' cask 'telegram-desktop' cask 'the-unarchiver' cask 'tinkerwell' -cask 'transmission' cask 'transmit' cask 'tunnelbear' cask 'tuple' cask 'visual-studio-code' -cask 'vlc' cask 'zoom' # Quicklook @@ -96,11 +83,7 @@ cask 'font-source-sans-pro' cask 'font-source-serif-pro' # Mac App Store -mas 'Byword', id: 420212497 -mas 'Giphy Capture', id: 668208984 mas 'Keynote', id: 409183694 +mas 'MyWoosh', id: 1498889644 mas 'Numbers', id: 409203825 -mas 'Spark', id: 1176895641 mas 'Speedtest', id: 1153157709 -mas 'Things', id: 904280696 -mas 'Tweetbot', id: 1384080005 diff --git a/README.md b/README.md index 0d24a715b..a788ce853 100644 --- a/README.md +++ b/README.md @@ -8,13 +8,15 @@ This repository serves as my way to help me setup and maintain my Mac. It takes 📺 - [Watch the screencast on Laracasts](https://laracasts.com/series/guest-spotlight/episodes/1) 💡 - [Learn how to build your own dotfiles](https://github.com/driesvints/dotfiles#your-own-dotfiles) +If you find this repo useful, [consider sponsoring me](https://github.com/sponsors/driesvints) (a little bit)! ❤️ + ## A Fresh macOS Setup -These instructions are for when you've already set up your dotfiles. If you want to get started with your own dotfiles you can [find instructions below](#your-own-dotfiles). +These instructions are for setting up new Mac devices. Instead, if you want to get started building your own dotfiles, you can [find those instructions below](#your-own-dotfiles). -### Before you re-install +### Backup your data -First, go through the checklist below to make sure you didn't forget anything before you wipe your hard drive. +If you're migrating from an existing Mac, you should first make sure to backup all of your existing data. Go through the checklist below to make sure you didn't forget anything before you migrate. - Did you commit and push any changes/branches to your git repositories? - Did you remember to save all important documents from non-iCloud directories? @@ -22,16 +24,14 @@ First, go through the checklist below to make sure you didn't forget anything be - Did you remember to export important data from your local database? - Did you update [mackup](https://github.com/lra/mackup) to the latest version and ran `mackup backup`? -### Installing macOS cleanly - -After going to our checklist above and making sure you backed everything up, we're going to cleanly install macOS with the latest release. Follow [this article](https://www.imore.com/how-do-clean-install-macos) to cleanly install the latest macOS version. - ### Setting up your Mac -If you did all of the above you may now follow these install instructions to setup a new Mac. +After backing up your old Mac you may now follow these install instructions to setup a new one. -1. Update macOS to the latest version with the App Store -2. [Generate a new public and private SSH key](https://docs.github.com/en/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent) by running: +1. Update macOS to the latest version through system preferences +2. Setup an SSH key by using one of the two following methods + 2.1. If you use 1Password, install it with the 1Password [SSH agent](https://developer.1password.com/docs/ssh/get-started/#step-3-turn-on-the-1password-ssh-agent) and sync your SSH keys locally. + 2.2. Otherwise [generate a new public and private SSH key](https://docs.github.com/en/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent) by running: ```zsh curl https://raw.githubusercontent.com/driesvints/dotfiles/HEAD/ssh.sh | sh -s "" @@ -40,21 +40,26 @@ If you did all of the above you may now follow these install instructions to set 3. Clone this repo to `~/.dotfiles` with: ```zsh - git clone git@github.com:driesvints/dotfiles.git ~/.dotfiles + git clone --recursive git@github.com:driesvints/dotfiles.git ~/.dotfiles ``` 4. Run the installation with: ```zsh - ~/.dotfiles/install.sh + cd ~/.dotfiles && ./fresh.sh ``` -5. After mackup is synced with your cloud storage, restore preferences by running `mackup restore` -6. Restart your computer to finalize the process +5. Start `Herd.app` and run its install process +6. After mackup is synced with your cloud storage, restore preferences by running `mackup restore` +7. Restart your computer to finalize the process Your Mac is now ready to use! -> 💡 You can use a different location than `~/.dotfiles` if you want. Make sure you also update the reference in the [`.zshrc`](./.zshrc#L2) file. +> 💡 You can use a different location than `~/.dotfiles` if you want. Make sure you also update the references in the [`.zshrc`](./.zshrc#L2) and [`fresh.sh`](./fresh.sh#L20) files. + +### Cleaning your old Mac (optionally) + +After you've set up your new Mac you may want to wipe and clean install your old Mac. Follow [this article](https://support.apple.com/guide/mac-help/erase-and-reinstall-macos-mh27903/mac) to do that. Remember to [backup your data](#backup-your-data) first! ## Your Own Dotfiles @@ -64,7 +69,7 @@ If you want to start with your own dotfiles from this setup, it's pretty easy to Go through the [`.macos`](./.macos) file and adjust the settings to your liking. You can find much more settings at [the original script by Mathias Bynens](https://github.com/mathiasbynens/dotfiles/blob/master/.macos) and [Kevin Suttle's macOS Defaults project](https://github.com/kevinSuttle/MacOS-Defaults). -Check out the [`Brewfile`](./Brewfile) file and adjust the apps you want to install for your machine. Use [their search page](https://caskroom.github.io/search) to check if the app you want to install is available. +Check out the [`Brewfile`](./Brewfile) file and adjust the apps you want to install for your machine. Use [their search page](https://formulae.brew.sh/cask/) to check if the app you want to install is available. Check out the [`aliases.zsh`](./aliases.zsh) file and add your own aliases. If you need to tweak your `$PATH` check out the [`path.zsh`](./path.zsh) file. These files get loaded in because the `$ZSH_CUSTOM` setting points to the `.dotfiles` directory. You can adjust the [`.zshrc`](./.zshrc) file to your liking to tweak your Oh My Zsh setup. More info about how to customize Oh My Zsh can be found [here](https://github.com/robbyrussell/oh-my-zsh/wiki/Customization). @@ -81,6 +86,6 @@ Enjoy your own Dotfiles! ## Thanks To... -I first got the idea for starting this project by visiting the [GitHub does dotfiles](https://dotfiles.github.io/) project. Both [Zach Holman](https://github.com/holman/dotfiles) and [Mathias Bynens](https://github.com/mathiasbynens/dotfiles) were great sources of inspiration. [Sourabh Bajaj](https://twitter.com/sb2nov/)'s [Mac OS X Setup Guide](http://sourabhbajaj.com/mac-setup/) proved to be invaluable. Thanks to [@subnixr](https://github.com/subnixr) for [his awesome Zsh theme](https://github.com/subnixr/minimal)! And lastly, I'd like to thank [Emma Fabre](https://twitter.com/anahkiasen) for [her excellent presentation on Homebrew](https://speakerdeck.com/anahkiasen/a-storm-homebrewin) which made me migrate a lot to a [`Brewfile`](./Brewfile) and [Mackup](https://github.com/lra/mackup). +I first got the idea for starting this project by visiting the [GitHub does dotfiles](https://dotfiles.github.io/) project. Both [Zach Holman](https://github.com/holman/dotfiles) and [Mathias Bynens](https://github.com/mathiasbynens/dotfiles) were great sources of inspiration. [Sourabh Bajaj](https://twitter.com/sb2nov/)'s [Mac OS X Setup Guide](http://sourabhbajaj.com/mac-setup/) proved to be invaluable. Thanks to [@subnixr](https://github.com/subnixr) for [his awesome Zsh theme](https://github.com/subnixr/minimal)! Thanks to [Caneco](https://twitter.com/caneco) for the header in this readme. And lastly, I'd like to thank [Emma Fabre](https://twitter.com/anahkiasen) for [her excellent presentation on Homebrew](https://speakerdeck.com/anahkiasen/a-storm-homebrewin) which made me migrate a lot to a [`Brewfile`](./Brewfile) and [Mackup](https://github.com/lra/mackup). In general, I'd like to thank every single one who open-sources their dotfiles for their effort to contribute something to the open-source community. diff --git a/aliases.zsh b/aliases.zsh index 64a1cc2f2..f56abf71d 100644 --- a/aliases.zsh +++ b/aliases.zsh @@ -1,33 +1,37 @@ # Shortcuts alias copyssh="pbcopy < $HOME/.ssh/id_ed25519.pub" -alias reloadshell="source $HOME/.zshrc" +alias reloadshell="omz reload" alias reloaddns="dscacheutil -flushcache && sudo killall -HUP mDNSResponder" -alias ll="/usr/local/opt/coreutils/libexec/gnubin/ls -AhlFo --color --group-directories-first" +alias ll="/opt/homebrew/opt/coreutils/libexec/gnubin/ls -AhlFo --color --group-directories-first" alias phpstorm='open -a /Applications/PhpStorm.app "`pwd`"' alias shrug="echo '¯\_(ツ)_/¯' | pbcopy" -alias c="clear" +alias compile="commit 'compile'" +alias timestamp="date +%s" +alias version="commit 'version'" # Directories alias dotfiles="cd $DOTFILES" alias library="cd $HOME/Library" -alias sites="cd $HOME/Sites" -alias lara="sites && cd laravel/" -alias docs="lara && cd docs/" +alias projects="cd $HOME/Code" +alias sites="cd $HOME/Herd" # Laravel -alias a="php artisan" -alias fresh="php artisan migrate:fresh --seed" -alias seed="php artisan db:seed" +alias a="herd php artisan" +alias fresh="herd php artisan migrate:fresh --seed" +alias tinker="herd php artisan tinker" +alias seed="herd php artisan db:seed" +alias serve="herd php artisan serve" +alias cloud="php $HOME/Code/laravel/cloud-cli/cloud" # PHP alias cfresh="rm -rf vendor/ composer.lock && composer i" -alias php74="docker run -it -w /data -v ${PWD}:/data:delegated --entrypoint php --rm registry.gitlab.com/grahamcampbell/php:7.4" -alias php8="docker run -it -w /data -v ${PWD}:/data:delegated --entrypoint php --rm registry.gitlab.com/grahamcampbell/php:8.0" -alias composer="php -d memory_limit=-1 /usr/local/bin/composer" +alias composer="herd composer" +alias php="herd php" +alias test="pest --no-coverage" # JS alias nfresh="rm -rf node_modules/ package-lock.json && npm install" -alias watch="npm run watch" +alias watch="npm run dev" # Docker alias docker-composer="docker-compose" @@ -36,16 +40,17 @@ alias docker-composer="docker-compose" alias mssql="docker run -e ACCEPT_EULA=Y -e SA_PASSWORD=LaravelWow1986! -p 1433:1433 mcr.microsoft.com/mssql/server:2017-latest" # Git -alias gst="git status" -alias gb="git branch" +alias gs="git status" +alias gb="git branch --sort=-committerdate" alias gc="git checkout" alias gl="git log --oneline --decorate --color" alias amend="git add . && git commit --amend --no-edit" alias commit="git add . && git commit -m" alias diff="git diff" -alias force="git push --force" +alias force="git push --force-with-lease" alias nuke="git clean -df && git reset --hard" alias pop="git stash pop" +alias prune="git fetch --prune" alias pull="git pull" alias push="git push" alias resolve="git add . && git commit --no-edit" diff --git a/bin/debug b/bin/setup similarity index 61% rename from bin/debug rename to bin/setup index 3f11de531..45a657fb8 100755 --- a/bin/debug +++ b/bin/setup @@ -3,7 +3,13 @@ echo "Setting up test project..." REPOSITORY=$1 -DIRECTORY="$HOME/Sites/$2" +DIRECTORY="./$2" + +if [[ $PWD != "$HOME/Herd" ]]; then + echo "You can only setup projects in the $HOME/Herd directory." + + exit 1 +fi if [ -z "$REPOSITORY" ] || [ -z "$DIRECTORY" ]; then echo "Please provide both a repository and target directory." @@ -14,16 +20,18 @@ fi git clone $REPOSITORY $DIRECTORY cd $DIRECTORY +touch database/database.sqlite + cp .env.example .env sed -i '' 's/DB_DATABASE=.*/DB_DATABASE=laravel/' .env sed -i '' 's/DB_USERNAME=.*/DB_USERNAME=root/' .env -sed -i '' 's/DB_PASSWORD=.*/DB_PASSWORD=password/' .env +sed -i '' 's/DB_PASSWORD=.*/DB_PASSWORD=/' .env composer install php artisan key:generate php artisan migrate:fresh --seed npm install -npm run dev +npm run build -open -a /Applications/PhpStorm.app "`pwd`" +open -a "/Applications/Visual Studio Code.app" "`pwd`" diff --git a/clone.sh b/clone.sh index ea8ae4835..5d3374014 100755 --- a/clone.sh +++ b/clone.sh @@ -2,40 +2,42 @@ echo "Cloning repositories..." -SITES=$HOME/Sites -BLADE=$SITES/blade-ui-kit -EVENTSAUCE=$SITES/eventsauce -LARAVEL=$SITES/laravel +CODE=$HOME/Code +SITES=$HOME/Herd +BLADE=$CODE/blade-ui-kit +LARAVEL=$CODE/laravel -# Personal +# Sites +git clone git@github.com:blade-ui-kit/blade-ui-kit.com.git $SITES/blade-ui-kit.com +git clone git@github.com:laravel/blog.laravel.com.git $SITES/blog.laravel.com +git clone git@github.com:blade-ui-kit/demo.git $SITES/demo.blade-ui-kit.com git clone git@github.com:driesvints/driesvints.com.git $SITES/driesvints.com -git clone git@github.com:fullstackbelgium/fullstackbelgium.be.git $SITES/fullstackbelgium.be +git clone git@github.com:laravel/envoyer.git $SITES/envoyer +git clone git@github.com:eventyio/eventy.io.git $SITES/eventy.io +git clone git@github.com:laravel/forge.git $SITES/forge git clone git@github.com:fullstackeurope/fullstackeurope.com.git $SITES/fullstackeurope.com +git clone git@github.com:laravel/laravel.com.git $SITES/laravel.com git clone git@github.com:laravelio/laravel.io.git $SITES/laravel.io git clone git@github.com:laravelio/paste.laravel.io.git $SITES/paste.laravel.io +git clone git@github.com:laravel/nova.laravel.com.git $SITES/nova +git clone git@github.com:laravel/spark.laravel.com.git $SITES/spark.laravel.com +git clone git@github.com:laravel/vapor.git $SITES/vapor + +# Personal +git clone git@github.com:lmsqueezy/laravel.git $CODE/lmsqueezy-laravel +git clone git@github.com:driesvints/vat-calculator.git $CODE/vat-calculator # Blade UI Kit -git clone git@github.com:blade-ui-kit/awesome-tall-stack.git $BLADE/awesome-tall-stack git clone git@github.com:blade-ui-kit/blade-docs.git $BLADE/blade-docs git clone git@github.com:blade-ui-kit/blade-heroicons.git $BLADE/blade-heroicons git clone git@github.com:blade-ui-kit/blade-icons.git $BLADE/blade-icons git clone git@github.com:blade-ui-kit/blade-ui-kit.git $BLADE/blade-ui-kit -git clone git@github.com:blade-ui-kit/blade-ui-kit.com.git $BLADE/blade-ui-kit.com -git clone git@github.com:blade-ui-kit/blade-zondicons.git $BLADE/blade-zondicons git clone git@github.com:blade-ui-kit/docs.git $BLADE/docs -git clone git@github.com:blade-ui-kit/tallstack.dev.git $BLADE/tallstack.dev - -# EventSauce -git clone git@github.com:EventSaucePHP/Clock.git $EVENTSAUCE/Clock -git clone git@github.com:EventSaucePHP/DoctrineMessageRepository.git $EVENTSAUCE/DoctrineMessageRepository -git clone git@github.com:EventSaucePHP/DoctrineOutboxMessageDispatcher.git $EVENTSAUCE/DoctrineOutboxMessageDispatcher -git clone git@github.com:EventSaucePHP/EventSauce.git $EVENTSAUCE/EventSauce -git clone git@github.com:EventSaucePHP/LaravelEventSauce.git $EVENTSAUCE/LaravelEventSauce -git clone git@github.com:EventSaucePHP/RabbitMQBundleBindings.git $EVENTSAUCE/RabbitMQBundleBindings -git clone git@github.com:EventSaucePHP/RectorFrom0to1.git $EVENTSAUCE/RectorFrom0to1 # Laravel +git clone git@github.com:laravel/beep.git $LARAVEL/beep git clone git@github.com:laravel/breeze.git $LARAVEL/breeze +git clone git@github.com:laravel/breeze-next.git $LARAVEL/breeze-next git clone git@github.com:laravel/browser-kit-testing.git $LARAVEL/browser-kit-testing git clone git@github.com:laravel/cashier-stripe.git $LARAVEL/cashier-stripe git clone git@github.com:laravel/cashier-paddle.git $LARAVEL/cashier-paddle @@ -43,6 +45,8 @@ git clone git@github.com:laravel/docs.git $LARAVEL/docs git clone git@github.com:laravel/dusk.git $LARAVEL/dusk git clone git@github.com:laravel/echo.git $LARAVEL/echo git clone git@github.com:laravel/envoy.git $LARAVEL/envoy +git clone git@github.com:laravel/folio.git $LARAVEL/folio +git clone git@github.com:laravel/forge-cli.git $LARAVEL/forge-cli git clone git@github.com:laravel/forge-sdk.git $LARAVEL/forge-sdk git clone git@github.com:laravel/fortify.git $LARAVEL/fortify git clone git@github.com:laravel/framework.git $LARAVEL/framework @@ -50,24 +54,38 @@ git clone git@github.com:laravel/helpers.git $LARAVEL/helpers git clone git@github.com:laravel/horizon.git $LARAVEL/horizon git clone git@github.com:laravel/installer.git $LARAVEL/installer git clone git@github.com:laravel/jetstream.git $LARAVEL/jetstream +git clone git@github.com:laravel/jetstream-docs.git $LARAVEL/jetstream-docs git clone git@github.com:laravel/laravel.git $LARAVEL/laravel -git clone git@github.com:laravel/laravel.com-next.git $LARAVEL/laravel.com-next git clone git@github.com:laravel/legacy-factories.git $LARAVEL/legacy-factories git clone git@github.com:laravel/lumen.git $LARAVEL/lumen git clone git@github.com:laravel/lumen-framework.git $LARAVEL/lumen-framework -git clone git@github.com:laravel/nexmo-notification-channel.git $LARAVEL/nexmo-notification-channel git clone git@github.com:laravel/nova.git $LARAVEL/nova git clone git@github.com:laravel/octane.git $LARAVEL/octane +git clone git@github.com:laravel/package-template.git $LARAVEL/package-template +git clone git@github.com:laravel/pail.git $LARAVEL/pail git clone git@github.com:laravel/passport.git $LARAVEL/passport +git clone git@github.com:laravel/pennant.git $LARAVEL/pennant +git clone git@github.com:laravel/pint.git $LARAVEL/pint +git clone git@github.com:laravel/precognition.git $LARAVEL/precognition +git clone git@github.com:laravel/prompts.git $LARAVEL/prompts +git clone git@github.com:laravel/pulse.git $LARAVEL/pulse git clone git@github.com:laravel/sail.git $LARAVEL/sail git clone git@github.com:laravel/sail-server.git $LARAVEL/sail-server git clone git@github.com:laravel/sanctum.git $LARAVEL/sanctum git clone git@github.com:laravel/scout.git $LARAVEL/scout +git clone git@github.com:laravel/serializable-closure.git $LARAVEL/serializable-closure git clone git@github.com:laravel/slack-notification-channel.git $LARAVEL/slack-notification-channel git clone git@github.com:laravel/socialite.git $LARAVEL/socialite +git clone git@github.com:laravel/spark-next-docs.git $LARAVEL/spark-next-docs git clone git@github.com:laravel/spark-paddle.git $LARAVEL/spark-paddle git clone git@github.com:laravel/spark-stripe.git $LARAVEL/spark-stripe git clone git@github.com:laravel/telescope.git $LARAVEL/telescope git clone git@github.com:laravel/tinker.git $LARAVEL/tinker git clone git@github.com:laravel/ui.git $LARAVEL/ui +git clone git@github.com:laravel/valet.git $LARAVEL/valet +git clone git@github.com:laravel/vapor-cli.git $LARAVEL/vapor-cli +git clone git@github.com:laravel/vapor-core.git $LARAVEL/vapor-core git clone git@github.com:laravel/vapor-ui.git $LARAVEL/vapor-ui +git clone git@github.com:laravel/vite-plugin.git $LARAVEL/vite-plugin +git clone git@github.com:livewire/volt.git $LARAVEL/volt +git clone git@github.com:laravel/vonage-notification-channel.git $LARAVEL/vonage-notification-channel diff --git a/install.sh b/fresh.sh similarity index 61% rename from install.sh rename to fresh.sh index f0b7640f0..a935abd60 100755 --- a/install.sh +++ b/fresh.sh @@ -2,6 +2,14 @@ echo "Setting up your Mac..." +# Check if Xcode Command Line Tools are installed +if ! xcode-select -p &>/dev/null; then + echo "Xcode Command Line Tools not found. Installing..." + xcode-select --install +else + echo "Xcode Command Line Tools already installed." +fi + # Check for Oh My Zsh and install if we don't have it if test ! $(which omz); then /bin/sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/HEAD/tools/install.sh)" @@ -10,44 +18,38 @@ fi # Check for Homebrew and install if we don't have it if test ! $(which brew); then /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" + + echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> $HOME/.zprofile + eval "$(/opt/homebrew/bin/brew shellenv)" fi +# Removes .zshrc from $HOME (if it exists) and symlinks the .zshrc file from the .dotfiles +rm -rf $HOME/.zshrc +ln -sw $HOME/.dotfiles/.zshrc $HOME/.zshrc + # Update Homebrew recipes brew update # Install all our dependencies with bundle (See Brewfile) brew tap homebrew/bundle -brew bundle +brew bundle --file ./Brewfile # Set default MySQL root password and auth type mysql -u root -e "ALTER USER root@localhost IDENTIFIED WITH mysql_native_password BY 'password'; FLUSH PRIVILEGES;" -# Install PHP extensions with PECL -pecl install imagick memcached redis swoole +# Create a projects directories +mkdir $HOME/Code +mkdir $HOME/Herd -# Install global Composer packages -/usr/local/bin/composer global require laravel/installer laravel/valet beyondcode/expose - -# Install Laravel Valet -$HOME/.composer/vendor/bin/valet install - -# Create a Sites directory -mkdir $HOME/Sites - -# Create sites subdirectories -mkdir $HOME/Sites/blade-ui-kit -mkdir $HOME/Sites/eventsauce -mkdir $HOME/Sites/laravel +# Create Code subdirectories +mkdir $HOME/Code/blade-ui-kit +mkdir $HOME/Code/laravel # Clone Github repositories ./clone.sh -# Removes .zshrc from $HOME (if it exists) and symlinks the .zshrc file from the .dotfiles -rm -rf $HOME/.zshrc -ln -s $HOME/.dotfiles/.zshrc $HOME/.zshrc - # Symlink the Mackup config file to the home directory -ln -s $HOME/.dotfiles/.mackup.cfg $HOME/.mackup.cfg +ln -s ./.mackup.cfg $HOME/.mackup.cfg # Set macOS preferences - we will run this last because this will reload the shell -source .macos +source ./.macos diff --git a/minimal.zsh-theme b/minimal.zsh-theme index cd5030d34..918d14526 100644 --- a/minimal.zsh-theme +++ b/minimal.zsh-theme @@ -160,11 +160,12 @@ function mnml_jobs { } function mnml_files { + local _ls="$(env which ls)" local _w="%{\e[0m%}" local _g="%{\e[38;5;244m%}" - local a_files="$(ls -1A | sed -n '$=')" - local v_files="$(ls -1 | sed -n '$=')" + local a_files="$($_ls -1A | sed -n '$=')" + local v_files="$($_ls -1 | sed -n '$=')" local h_files="$((a_files - v_files))" local output="${_w}[$_g${v_files:-0}" @@ -191,7 +192,7 @@ function mnml_me_ls { if [ "$(uname)" = "Darwin" ] && ! ls --version &> /dev/null; then COLUMNS=$COLUMNS CLICOLOR_FORCE=1 ls -C -G -F else - ls -C -F --color="always" -w $COLUMNS + env ls -C -F --color="always" -w $COLUMNS fi } @@ -295,4 +296,4 @@ RPROMPT='$(_mnml_wrap MNML_RPROMPT)' _mnml_bind_widgets bindkey -M main "^M" buffer-empty -bindkey -M vicmd "^M" buffer-empty \ No newline at end of file +bindkey -M vicmd "^M" buffer-empty diff --git a/path.zsh b/path.zsh index d8a700f67..3f0c50fa4 100644 --- a/path.zsh +++ b/path.zsh @@ -1,16 +1,19 @@ +# Add directories to the PATH and prevent to add the same directory multiple times upon shell reload. +add_to_path() { + if [[ -d "$1" ]] && [[ ":$PATH:" != *":$1:"* ]]; then + export PATH="$1:$PATH" + fi +} + # Load dotfiles binaries -export PATH="$DOTFILES/bin:$PATH" +add_to_path "$DOTFILES/bin" -# Load Composer tools -export PATH="$HOME/.composer/vendor/bin:$PATH" +# Load global Composer tools +add_to_path "$HOME/.composer/vendor/bin" -# Load Node global installed binaries -export PATH="$HOME/.node/bin:$PATH" +# Load global Node installed binaries +add_to_path "$HOME/.node/bin" # Use project specific binaries before global ones -export PATH="node_modules/.bin:vendor/bin:$PATH" - -# Make sure coreutils are loaded before system commands -# I've disabled this for now because I only use "ls" which is -# referenced in my aliases.zsh file directly. -#export PATH="$(brew --prefix coreutils)/libexec/gnubin:$PATH" +add_to_path "vendor/bin" +add_to_path "node_modules/.bin" diff --git a/plugins/artisan b/plugins/artisan new file mode 160000 index 000000000..d097c375f --- /dev/null +++ b/plugins/artisan @@ -0,0 +1 @@ +Subproject commit d097c375fcfc29af15172d6d7f4005187106d847