type below:
brew update
brew install redis
To have launchd start redis now and restart at login:
brew services start redis
type below:
brew update
brew install redis
To have launchd start redis now and restart at login:
brew services start redis
package main | |
import ( | |
"fmt" | |
"math/big" | |
) | |
func main() { | |
fmt.Println(Fib(1000)) | |
} |
package main | |
import ( | |
"bytes" | |
"fmt" | |
"unicode" | |
) | |
func main() { |
package util | |
// chunk the file into smaller pieces | |
func Chunks(path string) (parts uint64, filepath string) { | |
file := openFile(path) | |
defer closeFile(file) | |
fileInfo := fileInfo(file) |
package util | |
import ( | |
"time" | |
) | |
// convert hour to timestamp | |
// this function assume the parameter as an hour in a day |
deb http://archive.ubuntu.com/ubuntu bionic main multiverse restricted universe | |
deb http://archive.ubuntu.com/ubuntu bionic-security main multiverse restricted universe | |
deb http://archive.ubuntu.com/ubuntu bionic-updates main multiverse restricted universe |
; Sample supervisor config file. | |
; | |
; For more information on the config file, please see: | |
; http://supervisord.org/configuration.html | |
; | |
; Note: shell expansion ("~" or "$HOME") is not supported. Environment | |
; variables can be expanded using this syntax: "%(ENV_HOME)s". | |
[unix_http_server] | |
file=/tmp/supervisor.sock ; (the path to the socket file) |
#!/usr/bin/env bash | |
# https://developers.supportbee.com/blog/setting-up-cucumber-to-run-with-Chrome-on-Linux/ | |
# https://gist.github.com/curtismcmullan/7be1a8c1c841a9d8db2c | |
# http://stackoverflow.com/questions/10792403/how-do-i-get-chrome-working-with-selenium-using-php-webdriver | |
# http://stackoverflow.com/questions/26133486/how-to-specify-binary-path-for-remote-chromedriver-in-codeception | |
# http://stackoverflow.com/questions/40262682/how-to-run-selenium-3-x-with-chrome-driver-through-terminal | |
# http://askubuntu.com/questions/760085/how-do-you-install-google-chrome-on-ubuntu-16-04 | |
# Versions | |
CHROME_DRIVER_VERSION=`curl -sS chromedriver.storage.googleapis.com/LATEST_RELEASE` |
<?php | |
class DemoSubject implements SplSubject{ | |
private $observer, $value; | |
public function __construct(){ | |
$this->observers = array(); | |
} | |