{__/} ( • . •) / >❤️
This file contains 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 node | |
// Required parameters: | |
// @raycast.schemaVersion 1 | |
// @raycast.title zxy-generate notion daily titles | |
// @raycast.mode fullOutput | |
// Optional parameters: | |
// @raycast.icon 🤖 |
This file contains 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
const gulp = require("gulp"); | |
const sourcemaps = require("gulp-sourcemaps"); | |
const ts = require("gulp-typescript"); | |
const tsProject = ts.createProject("tsconfig.json"); | |
const cssInput = "src/**/*.css"; | |
const output = "out"; | |
function typescript(cb) { | |
tsProject |
This file contains 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/true | |
source="$0" | |
compiled="$0"c | |
if [[ "$source" -nt "$compiled" ]]; then | |
DEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer xcrun swiftc -sdk /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk -g "$source" -o "$compiled" || exit | |
fi | |
"$compiled" |
This file contains 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
javascript: (function() { | |
url = 'https://sourcegraph.com/' + location.href.replace(/(^\w+:|^)\/\//, ''); | |
window.open(url, '__blank'); | |
})(); |
This file contains 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
struct Version { | |
let rawValue: String | |
init(_ string: String) { | |
self.rawValue = string | |
} | |
enum CompareResult { | |
case greaterThan | |
case equal |
This file contains 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
class HDFSClient | |
attr_accessor :prefix_url | |
def initialize(prefix_url) | |
prefix_url.append("/") unless prefix_url.end_with?("/") | |
@prefix_url = prefix_url | |
end | |
def upload(file_name, file_path) | |
system "curl -i -L -s -X PUT -T #{file_path} \ | |
#{@prefix_url}#{file_name}\\?op\\=CREATE" |
This file contains 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
# 需要检查的 gem 以及对应的版本 | |
requireGems = { | |
'psych' => '>= 2.1', | |
} | |
# cocoapods & psych | |
requireGems.each do |gem_name, gem_ver_reqs| | |
gdep = Gem::Dependency.new(gem_name, *gem_ver_reqs) | |
found_gspec = gdep.matching_specs.max_by(&:version) | |
if found_gspec |
This file contains 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
#!/bin/sh | |
if [ "$#" -ne 1 ]; then | |
echo "Usage: $0 Author-Name" | |
exit 1 | |
fi | |
echo Total Commit: $(git log --author=$1 --pretty=tformat: --oneline | wc -l) | |
git log --author=$1 --pretty=tformat: --numstat | awk '{ add += $1; subs += $2; loc += $1 - $2 } END { printf "Added lines: %s, Removed lines: %s, Total lines: %s\n", add, subs, loc }' |
This file contains 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
editor | |
foreground: F5F5F5 | |
background: 1B1E1C | |
caret: AF5F00 | |
editor-selection | |
foreground: FFFFFF | |
background: 3E3E3E | |
H1 |
NewerOlder