This is inspired by A half-hour to learn Rust and Zig in 30 minutes.
Your first Go program as a classical "Hello World" is pretty simple:
First we create a workspace for our project:
| # press space + b and connect the usb port | |
| # build | |
| docker run -e keymap=iso_vim_arrow -e keyboard=dz60 --rm -v $('pwd'):/qmk:rw edasque/qmk_firmware | |
| # flash | |
| sudo dfu-programmer atmega32u4 erase --force | |
| sudo dfu-programmer atmega32u4 flash dz60_iso_vim_arrow.hex | |
| sudo dfu-programmer atmega32u4 reset |
| version: '2' | |
| services: | |
| api: | |
| volumes: | |
| - "nfsmount:${CONTAINER_DIR}" | |
| volumes: | |
| nfsmount: | |
| driver: local | |
| driver_opts: |
| > Thank you for reaching out to Autonomous! I am sorry to hear that you are having some trouble with your SmartDesk | |
| > but I will be glad to assist. It sounds like your system needs a "hard reset" can I please have you follow these | |
| > steps thoroughly. | |
| Reset Steps: | |
| 1. Unplug the desk for 20 seconds. Plug it back in. Wait a full 20 seconds. | |
| 2. Press the up and down buttons until the desk lowers all the way and beeps or 20 seconds pass. | |
| 3. Release both buttons. | |
| 4. Press the down buttons until the desk beeps one more time or 20 seconds pass. |
Creates an alias on the loopback interface (lo0) with the IP 10.254.254.254 on Mac OS X.
- Install the plist to:
/Library/LaunchDaemons/com.runlevel1.lo0.10.254.254.254.plist - Set mode:
chmod 0644 /Library/LaunchDaemons/com.runlevel1.lo0.10.254.254.254.plist - Set owner:
sudo chown root:wheel /Library/LaunchDaemons/com.runlevel1.lo0.10.254.254.254.plist - Load:
sudo launchctl load /Library/LaunchDaemons/com.runlevel1.lo0.10.254.254.254.plist
Our Virtual Machines are provisioned using Vagrant from a Linux base box to run using VirutalBox. If the Hard Disk space runs out and you cannot remove files to free-up space, you can resize the Hard Disk using some VirtualBox and Linux commands.
The following steps assume you've got a set-up like mine, where:
This tutorial guides you through creating your first Vagrant project.
We start with a generic Ubuntu VM, and use the Chef provisioning tool to:
- install packages for vim, git
- create user accounts, as specified in included JSON config files
- install specified user dotfiles (.bashrc, .vimrc, etc) from a git repository
Afterwards, we'll see how easy it is to package our newly provisioned VM
| #Session controller provides a token | |
| #/controllers/api/sessions_controller.rb | |
| class Api::SessionsController < Devise::SessionsController | |
| before_filter :authenticate_user!, :except => [:create] | |
| before_filter :ensure_params_exist, :except => [:destroy] | |
| respond_to :json | |
| def create | |
| resource = User.find_for_database_authentication(:email => params[:user_login][:email]) | |
| return invalid_login_attempt unless resource |