AstonJ
What's in your .bashrc/.zshrc?
Most Liked
connorlay
Here is one I recently stumbled upon in the documentation for IEx:
export ERL_AFLAGS='-kernel shell_history enabled'
This enables IEx shell history between sessions.
11
AstonJ
I am a sucker for shortcuts, so have just added these:
alias mixec="mix ecto.create"
alias mixem="mix ecto.migrate"
alias mixps="mix phx.server"
alias iexmixps="iex -S mix phx.server"
alias iexsmix="iex -S mix"
alias iexs="iex -S mix"
alias mixpr="mix phx.routes"
I also have various others, such as:
PS1="[\W]\$ "
alias ll="ls -lahG"
alias code="cd /Users/Aston/projects/code"
alias home="cd /Users/Aston"
alias oss="cd /Users/Aston/projects/oss"
alias desktop="cd /Users/Aston/desktop"
alias some_project_name="cd /Users/Aston/projects/code/some_project_name"
alias showhidden="defaults write com.apple.finder AppleShowAllFiles -boolean true ; killall Finder"
alias hidehidden="defaults write com.apple.finder AppleShowAllFiles -boolean false ; killall Finder"
vscode () { VSCODE_CWD="$PWD" open -n -b "com.microsoft.VSCode" --args $* ;}
Plus various others to shh to a server, upload/download files to/from a server, push certain scripts or rsync sites etc
4
adrianrl
Most of the time I use plugins from Sublime Text or Neovim to interact with Git, but here are a few aliases and functions. 
# Aliases
alias nv="nvim"
alias g="git"
alias ga="git add"
alias gaa="git add --all"
alias gb="git branch"
alias gc="git commit -m"
alias gca="git commit -a -m"
alias gcl="git clean -fd"
alias gcm="git checkout master"
alias gco="git checkout"
alias gcp="git cherry-pick"
alias gd="git diff"
alias gfo="git fetch origin"
alias ggpull="git pull origin $(git_current_branch)"
alias ggpush="git push origin $(git_current_branch)"
alias ghh="git help"
alias gl="git log"
alias gm="git merge"
alias gmom="git merge origin/master"
alias gp="git push"
alias gr="git reset"
alias grb="git rebase"
alias grh="git reset --hard"
alias gst="git status"
alias nah="git reset --hard && git clean -df"
alias mr="mix run"
alias mt="mix test"
alias ism="iex -S mix"
alias mdc="mix deps.clean"
alias mdg="mix deps.get"
alias mec="mix ecto.create"
alias mer="mix ecto.reset"
alias mes="mix ecto.setup"
alias mpr="mix phx.routes"
alias mps="mix phx.server"
# Functions
function zshconfig {
nvim ~/.zshrc
source ~/.zshrc
echo "ZSH config was reloaded."
}
function gclone {
git clone "https://github.com/${2:-$(whoami)}/$1.git"
}
function ginit {
git init
git add --all
git commit -m ${1:-"Init repo"}
}
4
Popular in Discussions
Hello everyone,
I know we had quite some threads (read through lots of them) about background job processing but it remains a hotly deba...
New
I asked this very same question on twitter and got some interesting feedback, but I thought it would be a good question to ask here as we...
New
AWS re:Invent is on at the moment with some interesting announcements. One new feature in particular is the Lambda Runtime API for AWS La...
New
What learn first? Rust or Elixir
Hi Elixir community!
I’m here because i want learn a new language. I’m a junior developer and mainly i ...
New
After doing a port from a c++ library to my project in phoenix I’ve seen that I need a faster way to run this algorithm and I found this ...
New
Hello everyone,
Long time lurker first time poster here. I’ve recently begun working on Elixir full-time again! :raised_hands: It’s been...
New
Hello,
Please pardon me for any faux paux. I am 46 and this is my first time on a forum of any kind. I wanted to to get answers from tho...
New
I’ve just started the Phoenix part of the utterly brilliant online course by @pragdave. On generating the Phoenix app he uses the --no-ec...
New
I would like to spark a discussion about the static access operator: ..
For whom does not know: it is used in Elixir to access fields of...
New
So, is Heroku the only free option for hosting Phoenix/Elixir at this point? I’m not ready to commit to paying monthly and was wondering ...
New
Other popular topics
Hello, can anybody help here..? I have a list of players and I what to delete an element, but every for loop the list is reverting to ori...
New
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service.
Currently when I de...
New
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
New
Hi everyone,
One of the features added to Elixir early on to help integration with Erlang code was the idea of overridable function defi...
New
I have an umbrella app.
Some of the apps inside depend on other apps in the umbrella, unsurprisingly.
I'm writing a test for one of t...
New
I have a relationship of love and hate with Elixir. Lots of things are just absolutely right, but there are some things that are kind of ...
New
I am using the Starship cross-shell prompt – it seems pretty nice, but I get some errors:
[WARN] - (starship::utils): Executing command ...
New
Currently suffering from paralysis by [HTTP client] analysis. This is rather unusual in Elixirland as there tends to be consensus on the ...
New
There are pre-rolled solutions for other frameworks that do work. However, Phoenix does not seem to have these. Have people had good expe...
New
For some reason my phoenix channels are working for me in my local dev environment, but as soon as I deploy via Docker, I get a 403 error...
New







