Skip to content

Commit 486b23e

Browse files
committed
MISC Updates
1 parent 28fa106 commit 486b23e

File tree

4 files changed

+29
-80
lines changed

4 files changed

+29
-80
lines changed

Brewfile

+6-6
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,17 @@ brew "zsh"
77
brew "pyenv"
88
brew "redis"
99
brew "postgresql@15"
10-
brew "pyenv"
1110
brew "rbenv"
1211
brew "n" # node manager https://github.com/tj/n
1312
brew "warp"
1413
brew "wget"
15-
brew "yarn"
1614
brew "skitch"
1715

1816
# For ruby 2.* to work:
19-
20-
brew "readline"
21-
brew "libyaml"
22-
brew "gmp"
17+
18+
# brew "readline"
19+
# brew "libyaml"
20+
# brew "gmp"
2321

2422
cask "latest" # Update apps easily
2523
cask "maccy" # Clipboard manager
@@ -38,3 +36,5 @@ cask "spotify"
3836
cask "zoom"
3937
tap "heroku/brew"
4038
brew "heroku"
39+
40+
brew "opensearch"

README.md

+6-35
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
- Install the software listed in the Brewfile:
4040

4141
```bash
42-
brew bundle --file ~/.macsetup/dotfiles/Brewfile
42+
brew bundle --file ~/.macsetup/Brewfile
4343
```
4444

4545
- Manually sign in to 1Password
@@ -83,22 +83,12 @@
8383
export RUBY_CONFIGURE_OPTS="--with-openssl-dir=$(brew --prefix [email protected])"
8484
```
8585

86-
- Follow instructiond for postgres app installation [here](sudo mkdir -p /etc/paths.d &&
87-
echo /Applications/Postgres.app/Contents/Versions/latest/bin | sudo tee /etc/paths.d/postgresapp). In short:
86+
- Create postgres role
8887

89-
```bash
90-
sudo mkdir -p /etc/paths.d &&
91-
echo /Applications/Postgres.app/Contents/Versions/latest/bin | sudo tee /etc/paths.d/postgresapp
92-
```
93-
94-
(In some situation I had to reinstall xcode)
95-
96-
- Allow gem install bundler to succeed:
97-
98-
```bash
99-
export GEM_HOME="$HOME/.gem"
100-
export RUBY_CONFIGURE_OPTS="--with-openssl-dir=$(brew --prefix [email protected])"
101-
```
88+
```
89+
createuser -s postgres
90+
brew services restart postgresql
91+
```
10292

10393
- Install node:
10494

@@ -110,22 +100,3 @@
110100

111101
- [Setup local git to your github account](https://gist.github.com/letiesperon/ce8217bc99195032f9dda3c67b424150)
112102
- [Setup Sublime preferences](https://gist.github.com/letiesperon/7090a100902871cb2b9f6941a1f430ed)
113-
114-
---
115-
116-
### Ruby projects considerations
117-
118-
I had to run
119-
120-
```ruby
121-
brew link postgresql@15 --force
122-
```
123-
124-
so that `pg` gem can be installed correctly.
125-
126-
When failing because role `postgres` is missing:
127-
128-
```
129-
createuser -s postgres
130-
brew services restart postgresql@15
131-
```

dotfiles/.gitconfig

+2
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,5 @@
1313
excludesFile = ~/.gitignore
1414
[init]
1515
defaultBranch = main
16+
[pager]
17+
branch = false

dotfiles/.zshrc

+15-39
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,30 @@
1-
# If you come from bash you might have to change your $PATH.
2-
# export PATH=$HOME/bin:/usr/local/bin:$PATH
1+
#!/bin/zsh
2+
3+
typeset -U path # Prevent duplicate entries on the $PATH
34

45
# ENV VARS
5-
export LANG=en_US.UTF-8
6+
export LANG="en_US.UTF-8"
67
export PYENV_ROOT="$HOME/.pyenv"
8+
export RBENV_ROOT="$HOME/.rbenv"
79
export ZSH="$HOME/.oh-my-zsh"
10+
export GEM_HOME="$HOME/.gem"
811
export N_PRESERVE_NPM=1
912
export N_PRESERVE_COREPACK=1
1013

11-
1214
# PATH
13-
export PATH="$PATH:$PYENV_ROOT/bin"
14-
export PATH="$PATH:/usr/local/sbin"
15+
path+=$N_PREFIX/bin
16+
path+=$PYENV_ROOT/bin
17+
path+=$RBENV_ROOT/shims
18+
path+=$GEM_HOME/bin # Ruby gems
19+
path=('/opt/homebrew/bin' '/opt/homebrew/sbin' $path) # Ensure Homebrew installed binaries take precedence
20+
export PATH # Export to sub-processes (make it inherited by child processes)
1521

1622
# Set name of the theme to load --- if set to "random", it will
1723
# load a random theme each time oh-my-zsh is loaded, in which case,
1824
# to know which specific one was loaded, run: echo $RANDOM_THEME
1925
# See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes
2026
ZSH_THEME="robbyrussell"
2127

22-
# Set list of themes to pick from when loading at random
23-
# Setting this variable when ZSH_THEME=random will cause zsh to load
24-
# a theme from this variable instead of looking in $ZSH/themes/
25-
# If set to an empty array, this variable will have no effect.
26-
# ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" )
27-
2828
# Uncomment the following line to use case-sensitive completion.
2929
# CASE_SENSITIVE="true"
3030

@@ -85,39 +85,15 @@ plugins=(
8585
zsh-syntax-highlighting
8686
)
8787

88-
# User configuration
89-
90-
# export MANPATH="/usr/local/man:$MANPATH"
91-
92-
# Preferred editor for local and remote sessions
93-
# if [[ -n $SSH_CONNECTION ]]; then
94-
# export EDITOR='vim'
95-
# else
96-
# export EDITOR='mvim'
97-
# fi
98-
99-
# Compilation flags
100-
# export ARCHFLAGS="-arch x86_64"
101-
102-
# Set personal aliases, overriding those provided by oh-my-zsh libs,
103-
# plugins, and themes. Aliases can be placed here, though oh-my-zsh
104-
# users are encouraged to define aliases within the ZSH_CUSTOM folder.
105-
# For a full list of active aliases, run `alias`.
106-
#
107-
# Example aliases
108-
# alias zshconfig="mate ~/.zshrc"
109-
# alias ohmyzsh="mate ~/.oh-my-zsh"
110-
11188
alias be="bundle exec"
112-
alias test-reset="bundle exec rake db:drop RAILS_ENV=test && bundle exec rake db:create RAILS_ENV=test && bundle exec rails db:schema:load RAILS_ENV=test"
113-
11489
alias brewery="brew update && brew upgrade && brew upgrade --cask && brew cleanup"
11590
alias c="clear"
91+
alias gitconfig="code $HOME/.gitconfig"
92+
alias macsetup="code $HOME/.macsetup"
11693
alias show_path="tr ':' '\n' <<< \"$PATH\""
11794
alias speedtest="networkQuality"
118-
alias gitconfig="code $HOME/.gitconfig"
95+
alias test-reset="bundle exec rake db:drop RAILS_ENV=test && bundle exec rake db:create RAILS_ENV=test && bundle exec rails db:schema:load RAILS_ENV=test"
11996
alias zshconfig="code $HOME/.zshrc"
120-
alias macsetup="code $HOME/.macsetup"
12197

12298
source $ZSH/oh-my-zsh.sh
12399

0 commit comments

Comments
 (0)