Skip to content

Commit

Permalink
feat: add vite press version
Browse files Browse the repository at this point in the history
  • Loading branch information
TigerZH committed Feb 21, 2022
1 parent b745e84 commit 9a8b7e2
Show file tree
Hide file tree
Showing 782 changed files with 41,283 additions and 10,964 deletions.
Binary file modified .DS_Store
Binary file not shown.
10 changes: 10 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[*]
charset = utf-8
indent_style = space
indent_size = 2
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
trim_trailing_whitespace = false
Binary file added .github/contributing/oxford-comma.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
109 changes: 109 additions & 0 deletions .github/contributing/writing-guide.md

Large diffs are not rendered by default.

16 changes: 16 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
version: 2
updates:
# Enable version updates for npm
- package-ecosystem: 'npm'
# Look for `package.json` and `lock` files in the `root` directory
directory: '/'
# Check the npm registry for updates every day (weekdays)
schedule:
interval: 'daily'
open-pull-requests-limit: 10
versioning-strategy: lockfile-only
allow:
- dependency-name: 'vue'
- dependency-name: 'vitepress'
- dependency-name: '@vue/theme'
- dependency-name: '@vue/repl'
5 changes: 5 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
## Description of Problem

## Proposed Solution

## Additional Information
42 changes: 42 additions & 0 deletions .github/scripts/tag-alert-blocks.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
#!/usr/bin/env node

const { exec } = require('child_process')

/**
* Execute a command and return stdout as string.
* @param {string} command
* @returns {Promise<string>}
*/
function run(command) {
return new Promise((resolve, reject) => {
exec(command, { encoding: 'utf-8' }, (error, stdout) =>
error ? reject(error) : resolve(stdout)
)
})
}

const ALERT_BLOCK = /^\+\s*:::\s?(\w+)/m

async function isUsingAlertBlock(base = 'origin/master') {
const result = await run(`git diff --name-only ${base}`)
const files = (
await Promise.all(
result
.trim()
.split(/\r?\n/)
.map(file =>
run(`git diff ${base} -- ${file}`)
.then(diff => ALERT_BLOCK.test(diff))
.then(usesAlertBlock => (usesAlertBlock ? file : ''))
)
)
).filter(Boolean)

if (files.length) {
return true
}

return false
}

module.exports = { isUsingAlertBlock }
23 changes: 23 additions & 0 deletions .github/workflows/automerge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Dependabot auto-merge
on: pull_request

permissions:
pull-requests: write
contents: write

jobs:
dependabot:
runs-on: ubuntu-latest
if: ${{ github.actor == 'dependabot[bot]' }}
steps:
- name: Dependabot metadata
id: metadata
uses: dependabot/fetch-metadata@v1.1.1
with:
github-token: '${{ secrets.GITHUB_TOKEN }}'
- name: Enable auto-merge for theme
if: ${{contains(steps.metadata.outputs.dependency-names, '@vue/theme') && steps.metadata.outputs.update-type != 'version-update:semver-major'}}
run: gh pr merge --auto --merge "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
71 changes: 0 additions & 71 deletions .github/workflows/codeql-analysis.yml

This file was deleted.

119 changes: 104 additions & 15 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,22 +1,111 @@
### OSX ###
# General
.DS_Store
node_modules
/dist
.AppleDouble
.LSOverride

# local env files
.env.local
.env.*.local
# Thumbnails
._*

# Log files
# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk

### Node ###
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
*.log
# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage
*.lcov

# nyc test coverage
.nyc_output

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# TypeScript v1 declaration files
typings/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# pnpm link folder
pnpm-global

# dotenv environment variables file
.env
.env.test

# parcel-bundler cache (https://parceljs.org/)
.cache

# rollup.js default build output
dist/

# vuepress build output
.vuepress/dist

# Serverless directories
.serverless/

# Temporary folders
tmp/
temp/
TODOs.md
src/api/index.json
src/examples/data.json
src/tutorial/data.json
draft.md
6 changes: 6 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"semi": false,
"singleQuote": true,
"trailingComma": "none",
"printWidth": 75
}
Loading

0 comments on commit 9a8b7e2

Please sign in to comment.