Phoenix 1.5 requires Elixir >= 1.7. Be sure your existing version is up to date by running elixir -v
on the command line.
$ mix archive.uninstall phx_new
$ mix archive.install hex phx_new 1.5.0
#!/bin/bash | |
####### | |
# Setup | |
####### | |
### Enable IPv4/6 forwarding: | |
# # In /etc/sysctl.d/30-ipforward.conf : | |
# net.ipv4.ip_forward=1 | |
# net.ipv6.conf.default.forwarding=1 | |
# net.ipv6.conf.all.forwarding=1 |
## BASIC | |
alias x='exit' | |
alias c='clear' | |
alias ll='ls -lh' # List files/dirs, `-l` with more details, `-h` show filesize in human-readable format | |
alias grep='grep --color=auto' # COLORSS! | |
## Routine | |
alias update='sudo apt update && apt list --upgradeable' # Check for updates | |
alias upgrade='sudo apt upgrade --auto-remove' # Install those updates | |
alias autoremove='sudo apt autoremove && sudo apt autoclean' # Run every few months to clear apt cache | |
alias aptinstall='sudo apt install' # Install something from apt |
Phoenix 1.4 ships with exciting new features, most notably with HTTP2 support, improved development experience with faster compile times, new error pages, and local SSL certificate generation. Additionally, our channel layer internals receiveced an overhaul, provided better structure and extensibility. We also shipped a new and improved Presence javascript API, as well as Elixir formatter integration for our routing and test DSLs.
This release requires few user-facing changes and should be a fast upgrade for those on Phoenix 1.3.x.
The mix phx.new archive can now be installed via hex, for a simpler, versioned installation experience.
To grab the new archive, simply run:
adb shell am | |
usage: am [subcommand] [options] | |
usage: am start [-D] [-W] [-P <FILE>] [--start-profiler <FILE>] | |
[--R COUNT] [-S] [--opengl-trace] <INTENT> | |
am startservice <INTENT> | |
am force-stop <PACKAGE> | |
am kill <PACKAGE> | |
am kill-all | |
am broadcast <INTENT> | |
am instrument [-r] [-e <NAME> <VALUE>] [-p <FILE>] [-w] |
# copied from default config | |
user nginx; | |
worker_processes 1; | |
error_log /var/log/nginx/error.log warn; | |
pid /var/run/nginx.pid; | |
events { | |
worker_connections 1024; | |
} |
Laravel-Mix is "an elegant wrapper around Webpack for the 80% use case". It has nothing to do with Elixir's Mix and does not require Laravel to work!
Create a new phoenix application with mix phx.new
. You may choose to add the --no-brunch
flag to stop brunch from being intiailized, but I personally prefer leaving that in and replacing brunch so that the folder structure is set up for me.
$ mix phx.new demo
CREATE TABLE test | |
( | |
id INTEGER, | |
parent INTEGER | |
); | |
INSERT INTO test (id, parent) VALUES | |
(1, NULL), | |
(2, 1), |
<title>Vue Awesome Autocomplete</title> | |
<link rel="stylesheet" href="https://unpkg.com/bulma/css/bulma.css"> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css"> | |
<link rel="stylesheet" href="style.css"> | |
<script src="https://unpkg.com/vue/dist/vue.js"></script> | |
<div id="app"> | |
<autocomplete-input | |
:options="options" | |
@select="onOptionSelect" |