diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..31e2b43 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,3 @@ +index.html -diff merge=ours +spec.js -diff merge=ours +spec.css -diff merge=ours diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..0106f82 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,19 @@ +name: Deploy spec + +on: [push] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v1 + with: + node-version: '12.x' + - run: npm install + - run: npm run build + - name: commit changes + uses: elstudio/actions-js-build/commit@v3 + with: + commitMessage: "fixup: [spec] `npm run build`" diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..434262c --- /dev/null +++ b/.gitignore @@ -0,0 +1,43 @@ +# Logs +logs +*.log +npm-debug.log* + +# Runtime data +pids +*.pid +*.seed + +# Directory for instrumented libs generated by jscoverage/JSCover +lib-cov + +# Coverage directory used by tools like istanbul +coverage + +# nyc test coverage +.nyc_output + +# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) +.grunt + +# node-waf configuration +.lock-wscript + +# Compiled binary addons (http://nodejs.org/api/addons.html) +build/Release + +# Dependency directories +node_modules +jspm_packages + +# Optional npm cache directory +.npm + +# Optional REPL history +.node_repl_history + +# Only apps should have lockfiles +yarn.lock +package-lock.json +npm-shrinkwrap.json +pnpm-lock.yaml diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000..43c97e7 --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +package-lock=false diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..6e78ec9 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2017 ECMA TC39 and contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..1bfd6cc --- /dev/null +++ b/README.md @@ -0,0 +1,60 @@ +# template-for-proposals + +A repository template for ECMAScript proposals. + +## Before creating a proposal + +Please ensure the following: + 1. You have read the [process document](https://tc39.github.io/process-document/) + 1. You have reviewed the [existing proposals](https://github.com/tc39/proposals/) + 1. You are aware that your proposal requires being a member of TC39, or locating a TC39 delegate to "champion" your proposal + +## Create your proposal repo + +Follow these steps: + 1. Click the green ["use this template"](https://github.com/tc39/template-for-proposals/generate) button in the repo header. (Note: Do not fork this repo in GitHub's web interface, as that will later prevent transfer into the TC39 organization) + 1. Go to your repo settings “Options” page, under “GitHub Pages”, and set the source to the **main branch** under the root (and click Save, if it does not autosave this setting) + 1. check "Enforce HTTPS" + 1. On "Options", under "Features", Ensure "Issues" is checked, and disable "Wiki", and "Projects" (unless you intend to use Projects) + 1. Under "Merge button", check "automatically delete head branches" + + 3. ["How to write a good explainer"][explainer] explains how to make a good first impression. + + > Each TC39 proposal should have a `README.md` file which explains the purpose + > of the proposal and its shape at a high level. + > + > ... + > + > The rest of this page can be used as a template ... + + Your explainer can point readers to the `index.html` generated from `spec.emu` + via markdown like + + ```markdown + You can browse the [ecmarkup output](https://ACCOUNT.github.io/PROJECT/) + or browse the [source](https://github.com/ACCOUNT/PROJECT/blob/HEAD/spec.emu). + ``` + + where *ACCOUNT* and *PROJECT* are the first two path elements in your project's Github URL. + For example, for github.com/**tc39**/**template-for-proposals**, *ACCOUNT* is "tc39" + and *PROJECT* is "template-for-proposals". + + +## Maintain your proposal repo + + 1. Make your changes to `spec.emu` (ecmarkup uses HTML syntax, but is not HTML, so I strongly suggest not naming it ".html") + 1. Any commit that makes meaningful changes to the spec, should run `npm run build` and commit the resulting output. + 1. Whenever you update `ecmarkup`, run `npm run build` and commit any changes that come from that dependency. + + [explainer]: https://github.com/tc39/how-we-work/blob/HEAD/explainer.md diff --git a/index.html b/index.html new file mode 100644 index 0000000..868e919 --- /dev/null +++ b/index.html @@ -0,0 +1,2319 @@ + + + + + +Proposal Title Goes Here

Stage -1 Draft / August 19, 2021

Proposal Title Goes Here

+ + +

1 This is an emu-clause

+

This is an algorithm:

+
  1. Let proposal be undefined.
  2. If IsAccepted(proposal),
    1. Let stage be 0.
  3. Else,
    1. Let stage be -1.
  4. Return ? ToString(proposal).
+
+

A Copyright & Software License

+ +

Copyright Notice

+

© 2021 Your Name(s) Here

+ +

Software License

+

All Software contained in this document ("Software") is protected by copyright and is being made available under the "BSD License", included below. This Software may be subject to third party rights (rights from parties other than Ecma International), including patent rights, and no licenses under such third party rights are granted under this license even if the third party concerned is a member of Ecma International. SEE THE ECMA CODE OF CONDUCT IN PATENT MATTERS AVAILABLE AT https://ecma-international.org/memento/codeofconduct.htm FOR INFORMATION REGARDING THE LICENSING OF PATENT CLAIMS THAT ARE REQUIRED TO IMPLEMENT ECMA INTERNATIONAL STANDARDS.

+ +

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

+ +
    +
  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. +
  3. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  4. +
  5. Neither the name of the authors nor Ecma International may be used to endorse or promote products derived from this software without specific prior written permission.
  6. +
+ +

THIS SOFTWARE IS PROVIDED BY THE ECMA INTERNATIONAL "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL ECMA INTERNATIONAL BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

+ +
+
\ No newline at end of file diff --git a/package.json b/package.json new file mode 100644 index 0000000..867ff95 --- /dev/null +++ b/package.json @@ -0,0 +1,19 @@ +{ + "private": true, + "name": "template-for-proposals", + "description": "A repository template for ECMAScript proposals.", + "scripts": { + "start": "npm run build-loose -- --watch", + "build": "npm run build-loose -- --strict", + "build-loose": "ecmarkup --verbose spec.emu index.html" + }, + "homepage": "https://github.com/tc39/template-for-proposals#readme", + "repository": { + "type": "git", + "url": "git+https://github.com/tc39/template-for-proposals.git" + }, + "license": "MIT", + "devDependencies": { + "ecmarkup": "^8.1.0" + } +} diff --git a/spec.emu b/spec.emu new file mode 100644 index 0000000..81dfaca --- /dev/null +++ b/spec.emu @@ -0,0 +1,23 @@ + + + + + +
+title: Proposal Title Goes Here
+stage: -1
+contributors: Your Name(s) Here
+
+ + +

This is an emu-clause

+

This is an algorithm:

+ + 1. Let _proposal_ be *undefined*. + 1. If IsAccepted(_proposal_), + 1. Let _stage_ be *0*. + 1. Else, + 1. Let _stage_ be *-1*. + 1. Return ? ToString(_proposal_). + +