Permalink
Browse files

🎉 Initial commit

  • Loading branch information...
wei committed May 22, 2018
0 parents commit a84bf7e70c7c7d753673b1ac1be35f6bee95eab3
Showing with 22,706 additions and 0 deletions.
  1. +3 −0 .babelrc
  2. +36 −0 .gitignore
  3. +12 −0 .travis.yml
  4. +63 −0 README.md
  5. +18,172 −0 package-lock.json
  6. +104 −0 package.json
  7. +21 −0 preact.config.js
  8. +4 −0 public/_redirects
  9. BIN public/assets/icon.png
  10. BIN public/favicon.ico
  11. +12 −0 public/manifest.json
  12. +80 −0 repos/wei/eslint/bug.json
  13. +52 −0 repos/wei/eslint/change.json
  14. +65 −0 repos/wei/eslint/new-rule.json
  15. +69 −0 repos/wei/eslint/rule-change.json
  16. +335 −0 schema/1.0.json
  17. +156 −0 schema/README.md
  18. +20 −0 src/components/heading/index.js
  19. +8 −0 src/components/heading/style.scss
  20. +58 −0 src/components/index.js
  21. +88 −0 src/components/input/index.js
  22. +91 −0 src/components/input/style.scss
  23. +35 −0 src/components/screen/issue-direct.js
  24. +31 −0 src/components/screen/issue-loading.js
  25. +59 −0 src/components/screen/main.js
  26. +42 −0 src/components/screen/style.scss
  27. +49 −0 src/components/style.scss
  28. +146 −0 src/helper/gh-helper.js
  29. +7 −0 src/helper/index.js
  30. +35 −0 src/helper/parse-repo.js
  31. +24 −0 src/helper/validate-schema.js
  32. +19 −0 src/index.ejs
  33. +66 −0 src/index.js
  34. +13 −0 test/repos.test.js
  35. +81 −0 test/sample-config/preact-cli.json
  36. +23 −0 test/sample-config/test-1.json
  37. +66 −0 test/src/components/__snapshots__/heading.test.js.snap
  38. +913 −0 test/src/components/__snapshots__/input.test.js.snap
  39. +53 −0 test/src/components/heading.test.js
  40. +405 −0 test/src/components/input.test.js
  41. +107 −0 test/src/components/screen/__snapshots__/issue-direct.test.js.snap
  42. +189 −0 test/src/components/screen/__snapshots__/issue-loading.test.js.snap
  43. +237 −0 test/src/components/screen/__snapshots__/main.test.js.snap
  44. +46 −0 test/src/components/screen/issue-direct.test.js
  45. +48 −0 test/src/components/screen/issue-loading.test.js
  46. +47 −0 test/src/components/screen/main.test.js
  47. +85 −0 test/src/helper/__snapshots__/gh-helper.test.js.snap
  48. +257 −0 test/src/helper/__snapshots__/parse-repo.test.js.snap
  49. +110 −0 test/src/helper/gh-helper.test.js
  50. +44 −0 test/src/helper/parse-repo.test.js
  51. +20 −0 test/src/helper/validate-schema.test.js
@@ -0,0 +1,3 @@
{
"presets": ["preact-widget-scripts/babel"]
}
@@ -0,0 +1,36 @@
# Logs
logs
*.log
npm-debug.log*

# 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

# Dependency directories
node_modules/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Output of 'npm pack'
*.tgz

# dotenv environment variables file
.env

# next.js build output
.next

build/
@@ -0,0 +1,12 @@
language: node_js
node_js:
- node
cache:
directories:
- node_modules
install:
- npm install
script:
- npm run lint
- npm run test
- NODE_ENV=production npm run build
@@ -0,0 +1,63 @@
<img align="right" width="150" height="150" title="new-issue logo"
src="https://user-images.githubusercontent.com/5880908/40338322-715df6b0-5d42-11e8-8d32-d1c86e954785.png" />

# New Issue

A fully customizable Github issues interface. Setup for your repo today!


## Introduction

Frustrated with issues that don't include enough information? Tired of limitation of Github Issue templates? Worry no more, _new-issue_ is here to rescue!

Showcase (Feel free to try it out):
- **Before:** <a target="_blank"
href="https://github.com/wei/eslint/issues/new?template=BUG_REPORT.md">https://github.com/wei/eslint/issues/new?template=BUG_REPORT.md</a>
- **After:** <a target="_blank"
href="https://new-issue.org/wei/eslint/bug">https://new-issue.org/wei/eslint/bug</a><br/><a target="_blank"
href="https://new-issue.org/wei/eslint/bug"><img width="50%" title="example new-issue"
src="https://user-images.githubusercontent.com/5880908/40338438-008836ac-5d43-11e8-945c-24f477921a3a.png" /></a>
## Get Started
Go to https://github.com/wei/new-issue/new/master/repos and create a file with name `:owner/:repo/index.json` following [this schema](schema/README.md).
Once the pull request is merged, you can start linking to `https://new-issue.org/:owner/:repo` in your `README.md` & `ISSUE_TEMPLATE.md` files.
## Schema
[View schema](schema/README.md)
## Advanced Usage
new-issue.org checks configuration in the following order (prepend `https://raw.githubusercontent.com/`):
1. `wei/new-issue/{master || :hash}/repos/:owner/:repo/{:type || index}.json`
2. `wei/new-issue/{master || :hash}/repos/:owner/index.json`
3. `:owner/:repo/{master || :hash}/.new-issue/{:type || index}.json`
4. `:owner/:repo/{master || :hash}/.new-issue`
_`:hash` can be commit hash or version number._


## TODOs
- [ ] Create bot to merge PRs automatically
- [ ] Better unit tests
- [ ] Add themes


## Authors

- [Wei He](https://whe.me) _github@weispot.com_


## License

[MIT](https://wei.mit-license.org)


## Disclaimer

Please do not use the service if your repo is mission critical. Functionalities are subject to change.
Oops, something went wrong.

0 comments on commit a84bf7e

Please sign in to comment.