The easiest way to get the ClamAV package is using Homebrew
$ brew install clamav
Before trying to start the clamd process, you'll need a copy of the ClamAV databases.
Create a freshclam.conf file and configure as so
| package main | |
| import ( | |
| "errors" | |
| "log" | |
| "github.com/libgit2/git2go" | |
| ) | |
| func checkoutBranch(repo *git.Repository, branchName string) error { | |
| checkoutOpts := &git.CheckoutOpts{ |
| # see https://www.topbug.net/blog/2013/04/14/install-and-use-gnu-command-line-tools-in-mac-os-x/ | |
| # core | |
| brew install coreutils | |
| # key commands | |
| brew install binutils | |
| brew install diffutils | |
| brew install ed --default-names | |
| brew install findutils --with-default-names |
| <?php | |
| /** | |
| *Reduce the strength requirement on the woocommerce password. | |
| * | |
| * Strength Settings | |
| * 3 = Strong (default) | |
| * 2 = Medium | |
| * 1 = Weak | |
| * 0 = Very Weak / Anything | |
| */ |
| /** | |
| * @param {Number} value | |
| * @param {Number} [bitCount = 0] | |
| * | |
| * @returns {String} binary representation of the two's complement of `value`. | |
| */ | |
| function twosComplement(value, bitCount) { | |
| let binaryStr; | |
| if (value >= 0) { |
The easiest way to get the ClamAV package is using Homebrew
$ brew install clamav
Before trying to start the clamd process, you'll need a copy of the ClamAV databases.
Create a freshclam.conf file and configure as so
| func (repo *Repo) Pull() error { | |
| branch, err := repo.Branch() | |
| if err != nil { | |
| return err | |
| } | |
| // Get the name | |
| name, err := branch.Name() | |
| if err != nil { | |
| return err |
| # This file should be in /etc/monit/conf.d | |
| check process hhvm with pidfile /var/run/hhvm/pid | |
| group hhvm | |
| # Start program calls our custom script from above | |
| start program = "/usr/local/sbin/start_hhvm.sh" | |
| stop program = "/usr/sbin/service hhvm stop" | |
| if failed unixsocket /var/run/hhvm/hhvm.sock then restart | |
| if mem > 400.0 MB for 1 cycles then restart | |
| if 5 restarts with 5 cycles then timeout |
| upstream transmission { | |
| server 127.0.0.1:9091; #Transmission | |
| } | |
| server { | |
| listen 443 ssl http2; | |
| server_name example.com; | |
| auth_basic "Server Restricted"; | |
| auth_basic_user_file /var/www/myWebSite/web/.htpasswd; | |
| # Path to the root of your installation |
| package main | |
| import ( | |
| "bufio" | |
| "crypto/aes" | |
| "crypto/cipher" | |
| "crypto/rand" | |
| "fmt" | |
| "io" | |
| "io/ioutil" |
This is a bash script that will automatically turn your wifi off if you connect your computer to an ethernet connection and turn wifi back on when you unplug your ethernet cable/adapter. If you decide to turn wifi on for whatever reason, it will remember that choice. This was improvised from this mac hint to work with Yosemite, and without hard-coding the adapter names. It's supposed to support growl, but I didn't check that part. I did, however, add OSX notification center support. Feel free to fork and fix any issues you encounter.
Most the credit for these changes go to Dave Holland.