Ref: https://docs.drone.io/installation/github/single-machine/
Set callback URL in github http://your-drone-ci-host:port/login
version: '3' | |
services: | |
postgres: | |
image: postgres:11 | |
restart: always | |
environment: | |
- "POSTGRES_USER=postgres" | |
- "POSTGRES_PASSWORD=postgres1234" | |
- "POSTGRES_DB=gogs" |
func dualPivotQuickSort(arr []int, start, end int) { | |
if start < end { | |
lp, rp := partition(arr, start, end) | |
dualPivotQuickSort(arr, start, lp-1) | |
dualPivotQuickSort(arr, lp+1, rp-1) | |
dualPivotQuickSort(arr, rp+1, end) | |
} | |
} | |
// partition split the slice into three parts with two pivots: |
Scritps: https://github.com/fuchsia-mirror/jiri/blob/master/scripts/bootstrap_jiri
From this script we can know the download URL can be got from: https://fuchsia-build.storage.googleapis.com/
Example (end with commit id)
fx script: https://github.com/fuchsia-mirror/scripts/blob/master/fx
#!/bin/bash | |
REPO_DIR=/tmp/my-git-repo | |
git clone -b $SOURCE_BRANCH $SOURCE_REPO_URL $REPO_DIR && cd $REPO_DIR || exit 1 | |
git remote add upstream $TARGET_REPO_URL && git fetch upstream $TARGET_REPO_BRANCH | |
commit_ids=$(git cherry upstream/$TARGET_REPO_BRANCH | awk '{print $2}') | |
cd - |
package main | |
// Just a sample code for learning mutex. Don't use this code for prodution. | |
import ( | |
"fmt" | |
"sync" | |
"time" | |
) |
grep -rnwH ./ -e WIN32 | sed -e 's/\(.*\):[0-9+].*/\1/' | sort | uniq | grep -v Binary | xargs vim |
import java.io.IOException; | |
import java.text.ChoiceFormat; | |
import java.text.Format; | |
import java.text.MessageFormat; | |
import java.text.NumberFormat; | |
import java.util.Locale; | |
import java.util.ResourceBundle; | |
public class App { |