通过第一篇《使用树莓派3B打造超强路由之一:初装》的努力,树莓派3B已经可以作为一台超低能耗、随身携带的开发用服务器来使用了。但这对于目标——打造超强路由而言,才刚刚开始。接下来,我们需要将其打磨成一台基本的无线路由器。
WARNING 本文所有指令均仅供参考,切勿无脑复制粘贴!
通过第一篇《使用树莓派3B打造超强路由之一:初装》的努力,树莓派3B已经可以作为一台超低能耗、随身携带的开发用服务器来使用了。但这对于目标——打造超强路由而言,才刚刚开始。接下来,我们需要将其打磨成一台基本的无线路由器。
WARNING 本文所有指令均仅供参考,切勿无脑复制粘贴!
| #!/bin/bash | |
| sudo apt-get install clang libicu-dev libcurl4-openssl-dev lldb git wget unzip -y | |
| wget https://swift.org/builds/swift-4.0-release/ubuntu1604/swift-4.0-RELEASE/swift-4.0-RELEASE-ubuntu16.04.tar.gz | |
| tar zxf swift-4.0*.tar.gz && rm -rf swift-4.0*.tar.gz | |
| sudo mv swift-4.0* /swift-4.0 | |
| echo "export PATH=/swift-4.0/usr/bin:\"\${PATH}\"" >> ~/.bashrc | |
| source ~/.bashrc |
Version numbers should be the ones you want. Here I do it with the last ones available at the moment of writing.
The simplest way to install elixir is using your package manager. Sadly, at the time of writing only Fedora shows
the intention to keep its packages up to date. There you can simply sudo dnf install erlang elixir and you are good to go.
Anyway, if you intend to work with several versions of erlang or elixir at the same time, or you are tied to
a specific version, you will need to compile it yourself. Then asdf is your best friend.
| # http://stackoverflow.com/questions/8507798/rails-3-1-plugin-gem-dummy-test-app-rspec | |
| # http://namick.tumblr.com/post/17663752365/how-to-create-a-gemified-plugin-with-rails-3-2-rspec | |
| rails plugin new plugin_name --skip-test-unit --dummy-path=spec/dummy | |
| cd plugin_name | |
| # Add rspec-rails to gemspec dev deps | |
| # s.add_development_dependency "rspec-rails" | |
| bundle install |
| import java.util.Iterator; | |
| import java.util.NoSuchElementException; | |
| // Introduction: | |
| // | |
| // This is an example class meant to illustrate several differen concepts: | |
| // * The use of type parameters (i.e. Java generics) | |
| // * Implementing an iterator over some collection, in this case an array | |
| // * Implementing the Iterable interface, which enables your collection | |
| // to work with the Java simple for loops, i.e. (for String s : list) |
| .../spec/spec_helper.rb:27:in `block (2 levels) in <top (required)>': uninitialized constant ControllerMacros (NameError) |