wget https://storage.googleapis.com/golang/go1.7.linux-armv6l.tar.gz
tar -C /usr/local -xzf go1.7.linux-armv6l.tar.gz
export PATH=$PATH:/usr/local/go/bin
//: Mocks Playground | |
import UIKit | |
struct User { | |
} | |
struct PushNotificationController { | |
let registrar: PushNotificationRegistrar | |
init(registrar: PushNotificationRegistrar) { |
db.Collection.find({ | |
created_at : { | |
'$gte': new Timestamp(new Date(2012, 0, 21), 0), | |
'$lte': new Timestamp(new Date(2012, 0, 22), 0) | |
}) |
I had some massive problems when installing the 10.13.3 update on macOS. The update installed, my computer successfully restarted - but on a subsequent restart the boot failed and displayed the following installation log:
Apr 4 04:07:04 MacBook-Pro opendirectoryd[186]: [session] Processing a network change notification
Apr 4 04:07:06 MacBook-Pro Unknown[526]: Launching the Language Chooser for an OS Install
Apr 4 04:07:06 MacBook-Pro bspowerassertiontool[521]: Tool exited successfully (0).
Apr 4 04:07:06 MacBook-Pro launchprogresswindow[524]: ISAP: Show progress UI called
Apr 4 04:07:07 MacBook-Pro Installer Progress[180]: Progress UI App Starting
Apr 4 04:07:32 MacBook-Pro opendirectoryd[186]: [session] Received a network change notification
Apr 4 04:07:32 MacBook-Pro opendirectoryd[186]: [session] Received a network change notification
import java.io.IOException; | |
import java.util.Properties; | |
import kafka.server.KafkaConfig; | |
import kafka.server.KafkaServerStartable; | |
public class KafkaLocal { | |
public KafkaServerStartable kafka; | |
public ZooKeeperLocal zookeeper; |
#Create bitbucket branch
##Create local branch
$ git checkout -b sync
Switched to a new branch 'sync'
$ git branch
master
* sync
# A little Meteor CheatSheet about Iron-Router. (updated on a weekly basis) | |
# Check our Studio: https://gentlenode.com/ | |
meteor add iron:router | |
meteor update iron:router | |
# Iron Router > Configuration |
Go has excellent build tools that mitigate the need for using make
.
For example, go install
won't update the target unless it's older
than the source files.
However, a Makefile can be convenient for wrapping Go commands with
specific build targets that simplify usage on the command line.
Since most of the targets are "phony", it's up to you to weigh the
pros and cons of having a dependency on make
versus using a shell
script. For the simplicity of being able to specify targets that
can be chained and can take advantage of make
's chained targets,
// Objective: demonstrate that there are more use cases | |
// for union types than previously thought. | |
// http://groups.google.com/group/golang-nuts/browse_thread/thread/fbde059a7cfd2fa9 | |
// | |
// Interface inference. | |
// We already have type inference, so this would be very Go-like: | |
type typeA int | |
func (x typeA) A() {} | |
func (x typeB) C() {} |
#!/usr/bin/env python | |
""" | |
Set terminal tab / decoration color by the server name. | |
Get a random colour which matches the server name and use it for the tab colour: | |
the benefit is that each server gets a distinct color which you do not need | |
to configure beforehand. | |
""" |