This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.PHONY: test | |
test: ## Run the tests | |
# TODO | |
.PHONY: lint | |
lint: ## Lint the soruce files | |
# TODO | |
.PHONY: build | |
build: ## Build the project |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func generatePrimesUntil(x int) []int { | |
t := []bool{false, true} | |
var p []int | |
for i := 3; i <= x; i++ { | |
t = append(t, true) | |
} | |
for i := 2; i < x; i++ { | |
if t[i] == true { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace :gridserver do | |
desc "Set the document root to be the 'current' symlink instead of the HTML directory" | |
task :set_document_root do | |
on roles(:app) do | |
document_root_path = "#{deploy_to}/html" | |
if test "[ -d #{document_root_path} ]" | |
info "Removing old document root symlink" | |
execute :rm, "#{document_root_path}" | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env php | |
<?php | |
/** | |
* ======================================================================================= | |
* Change constants below to match how you want the hook to work | |
* ======================================================================================= | |
*/ | |
define('ENABLE_FIRST_LINE_LENGTH_CHECK', 1); |