Skip to content

Commit 29c4b3e

Browse files
committed
sqlite v4
1 parent 97a30b9 commit 29c4b3e

60 files changed

Lines changed: 13988 additions & 3699 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.changelog.js

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
// This is an optional configuration file
2+
// you can use with changelog-version.
3+
// If specified, any command line args has priority over the
4+
// values returned in this file.
5+
6+
// All values are optional.
7+
// Do not use the ES6 export default
8+
// since the file is imported using require()
9+
// See command line options for additional available properties
10+
module.exports = {
11+
changelogFile: () => {
12+
return 'CHANGELOG.md'
13+
},
14+
// ==== Options specific to prepare ====
15+
newUnreleasedText: '### UNRELEASED\n\n',
16+
unreleasedTag: () => {
17+
return 'UNRELEASED'
18+
},
19+
unreleasedTagFormat: '{version} - {date}',
20+
requireUnreleasedEntry: true,
21+
requireUnreleasedEntryFailMsg: `You cannot commit until you've added the release notes to CHANGELOG.md
22+
23+
See CONTRIBUTING.md for instructions.`
24+
}

.circleci/config.yml

Lines changed: 108 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,108 @@
1+
# Javascript Node CircleCI 2.0 configuration file
2+
#
3+
# Check https://circleci.com/docs/2.0/language-javascript/ for more details
4+
#
5+
version: 2.1
6+
7+
npm-login: &npm-login
8+
# NPM_TOKEN is manually defined in CircleCI
9+
# project settings > Build settings > Environment variables
10+
# Add the NPM_TOKEN name and the value is your npm token
11+
# Get your npm token via npm token create
12+
# https://docs.npmjs.com/cli/token
13+
run:
14+
name: Create .npmrc
15+
command: |
16+
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" >> ~/.npmrc
17+
18+
orbs:
19+
node: circleci/node@1.1.6
20+
21+
jobs:
22+
test:
23+
executor:
24+
name: node/default
25+
tag: '10'
26+
working_directory: ~/repo
27+
steps:
28+
# Check out the git repo to the working directory
29+
- checkout
30+
- add_ssh_keys:
31+
fingerprints:
32+
# You need to add a deploy key with write permission in order for the CI to commit changes
33+
# back to the repo
34+
# https://circleci.com/docs/2.0/gh-bb-integration/#adding-readwrite-deployment-keys-to-github-or-bitbucket
35+
- "36:2c:16:f2:d0:59:13:25:f1:7f:44:87:a4:52:8f:03"
36+
# Download and cache dependencies so subsequent builds run faster
37+
- restore_cache:
38+
keys:
39+
- dependencies-{{ checksum "package-lock.json" }}
40+
# fallback to using the latest cache if no exact match is found
41+
- dependencies-
42+
- run:
43+
name: Install deps
44+
command: |
45+
npm i
46+
- save_cache:
47+
paths:
48+
- node_modules
49+
key: dependencies-{{ checksum "package-lock.json" }}
50+
- run:
51+
name: Run tests
52+
command: |
53+
npm run test:ci
54+
- run:
55+
name: Build the libraries
56+
command: |
57+
npm run build
58+
publish:
59+
executor:
60+
name: node/default
61+
tag: '12'
62+
working_directory: ~/repo
63+
steps:
64+
# Check out the git repo to the working directory
65+
- checkout
66+
# Create the .npmrc file so npm can auth for publishing
67+
- *npm-login
68+
- add_ssh_keys:
69+
fingerprints:
70+
# You need to add a deploy key with write permission in order for the CI to commit changes
71+
# back to the repo
72+
# https://circleci.com/docs/2.0/gh-bb-integration/#adding-readwrite-deployment-keys-to-github-or-bitbucket
73+
- "36:2c:16:f2:d0:59:13:25:f1:7f:44:87:a4:52:8f:03"
74+
# Download and cache dependencies so subsequent builds run faster
75+
- restore_cache:
76+
keys:
77+
- dependencies-{{ checksum "package-lock.json" }}
78+
# fallback to using the latest cache if no exact match is found
79+
- dependencies-
80+
- run:
81+
name: Install deps
82+
command: |
83+
npm i
84+
- save_cache:
85+
paths:
86+
- node_modules
87+
key: dependencies-{{ checksum "package-lock.json" }}
88+
- run:
89+
name: Build the libraries
90+
command: |
91+
npm run build
92+
- run:
93+
name: npm publish (master only)
94+
command: |
95+
.circleci/deploy.sh
96+
97+
workflows:
98+
version: 2
99+
build:
100+
jobs:
101+
- test
102+
- publish:
103+
filters:
104+
branches:
105+
only: master
106+
requires:
107+
- test
108+
context: npm-build

.circleci/deploy.sh

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
#!/bin/bash
2+
3+
if [[ "${CIRCLE_BRANCH}" == "master" ]]
4+
then
5+
set -e
6+
7+
echo "Raising package version and updating CHANGELOG.md"
8+
9+
git config --global push.default simple
10+
git config --global user.email "theo@suteki.nu"
11+
git config --global user.name "CircleCI Publisher"
12+
13+
# Stash any prior changes to prevent merge conflicts
14+
git stash
15+
16+
# Make sure to get the latest master (if there were any prior commits)
17+
git pull origin master
18+
19+
# Re-apply the stash
20+
# If there is nothing to apply on the stash, a non-zero exit code happens
21+
# we pipe an empty echo to prevent this
22+
git stash apply || echo ""
23+
24+
# Version bump package.json, stamp CHANGELOG.md
25+
npm run prepare-publish
26+
27+
# Changelog is now stamped with the version / time info - add to git
28+
git add CHANGELOG.md
29+
git add package.json
30+
31+
# Amend the version commit with a ci skip so when we push the commits from the CI
32+
# The CI does not end up recursively building it
33+
34+
# This gets the last commit log message
35+
PKG_VERSION=`npm run --silent version-bump show-version`
36+
37+
# Appending [skip ci] to the log message
38+
# Note: --amend does not trigger the pre-commit hooks
39+
git commit -m "${PKG_VERSION} [skip ci]"
40+
41+
git tag v${PKG_VERSION}
42+
43+
# Push the commits back to master and assign a versioned release tag
44+
# Had to add --force because the pull was getting rejected each time
45+
git push && git push origin "v${PKG_VERSION}"
46+
47+
# Publish the package to npm
48+
echo "Publishing package"
49+
npm publish
50+
else
51+
echo "Skipping - branch is not master"
52+
fi

.editorconfig

Lines changed: 0 additions & 20 deletions
This file was deleted.

.gitattributes

100644100755
Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,2 @@
1-
# Automatically normalize line endings for all text-based files
2-
# http://git-scm.com/docs/gitattributes#_end_of_line_conversion
3-
* text=auto
4-
5-
# For the following file types, normalize line endings to LF on
6-
# checkin and prevent conversion to CRLF when they are checked out
7-
# (this is required in order to prevent newline related issues like,
8-
# for example, after the build script is run)
9-
.* text eol=lf
10-
*.js text eol=lf
11-
*.json text eol=lf
12-
*.md text eol=lf
13-
*.txt text eol=lf
1+
# Prevent merge conflicts with CHANGELOG.md updates
2+
CHANGELOG.md merge=union

.gitignore

100644100755
Lines changed: 64 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,68 @@
1-
# Include your project-specific ignores in this file
2-
# Read about how to use .gitignore: https://help.github.com/articles/ignoring-files
3-
4-
build
5-
node_modules
1+
# Logs
2+
logs
63
*.log
74
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
8+
# Runtime data
9+
pids
10+
*.pid
11+
*.seed
12+
*.pid.lock
13+
14+
# Directory for instrumented libs generated by jscoverage/JSCover
15+
lib-cov
16+
17+
# Coverage directory used by tools like istanbul
18+
coverage
19+
20+
# nyc test coverage
21+
.nyc_output
22+
23+
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
24+
.grunt
25+
26+
# Bower dependency directory (https://bower.io/)
27+
bower_components
28+
29+
# node-waf configuration
30+
.lock-wscript
31+
32+
# Compiled binary addons (https://nodejs.org/api/addons.html)
33+
build/Release
34+
35+
# Dependency directories
36+
node_modules/
37+
jspm_packages/
38+
39+
# TypeScript v1 declaration files
40+
typings/
41+
42+
# Optional npm cache directory
843
.npm
9-
.eslint-cache
44+
45+
# Optional eslint cache
46+
.eslintcache
47+
48+
# Optional REPL history
49+
.node_repl_history
50+
51+
# Output of 'npm pack'
52+
*.tgz
53+
54+
# Yarn Integrity file
1055
.yarn-integrity
11-
.idea
56+
57+
# dotenv environment variables file
58+
.env
59+
60+
# next.js build output
61+
.next
62+
63+
.idea/
64+
test-report.xml
65+
lib/
66+
67+
build/
68+
coverage/

.npmignore

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
src/
2+
.babelrc
3+
test-report.xml
4+
.circleci/
5+
.idea/
6+
.wallaby.js
7+
__tests__/
8+
__mocks__/
9+
.gitattributes
10+
.gitignore
11+
.version-bump.js
12+
tsconfig.json
13+
.changelog.js
14+
.prettierrc
15+
jest.config.js
16+
CONTRIBUTING.md
17+
test-report.xml
18+
.quokka
19+
migrations/

.prettierrc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"trailingComma": "none"
3+
}

.travis.yml

Lines changed: 0 additions & 7 deletions
This file was deleted.

.version-bump.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
// This is an optional configuration file
2+
// If specified, any command line args has priority over the
3+
// values returned in this file.
4+
5+
// All values are optional.
6+
// Do not use the ES6 export default
7+
// since the file is imported using require()
8+
// See command line options for additional available properties
9+
module.exports = {
10+
strategy: 'cli'
11+
}

0 commit comments

Comments
 (0)