After pair programming with @Hazelfire, still need to fix playground scripts (rebase: README and index.js)
This commit is contained in:
parent
8f82f1fc47
commit
f492899117
8
.github/workflows/ci.yaml
vendored
8
.github/workflows/ci.yaml
vendored
|
@ -39,6 +39,8 @@ jobs:
|
|||
run: yarn build
|
||||
- name: Run tests
|
||||
run: yarn test
|
||||
- name: Run tsc and webpack
|
||||
run: yarn bundle
|
||||
|
||||
components-build-test:
|
||||
name: Components build and test
|
||||
|
@ -54,6 +56,6 @@ jobs:
|
|||
- name: Install packages
|
||||
run: yarn
|
||||
- name: See if storybook builds
|
||||
run: yarn build-storybook
|
||||
- name: Run tsc
|
||||
run: yarn ci
|
||||
run: yarn build
|
||||
- name: Run tsc and webpack
|
||||
run: yarn bundle
|
||||
|
|
|
@ -16,7 +16,7 @@ Squiggle is currently pre-alpha.
|
|||
|
||||
# Bug reports
|
||||
|
||||
Anyone (with a github account) can file an issue at any time. Please allow Quinn, Sam, and Ozzie to triage, but we encourage you to use either the `Bug` or `Enhancement` labels depending on the nature of the issue you're filing. `
|
||||
Anyone (with a github account) can file an issue at any time. Please allow Quinn, Sam, and Ozzie to triage, but otherwise just follow the suggestions in the issue templates.
|
||||
|
||||
# Project structure
|
||||
|
||||
|
|
22
README.md
22
README.md
|
@ -5,18 +5,18 @@ This is an experiment DSL/language for making probabilistic estimates.
|
|||
This monorepo has several packages that can be used for various purposes. All
|
||||
the packages can be found in `packages`.
|
||||
|
||||
`@squiggle/lang` in `packages/squiggle-lang` contains the core language, particularly
|
||||
`@quri/squiggle-lang` in `packages/squiggle-lang` contains the core language, particularly
|
||||
an interface to parse squiggle expressions and return descriptions of distributions
|
||||
or results.
|
||||
|
||||
`@squiggle/components` in `packages/components` contains React components that
|
||||
`@quri/squiggle-components` in `packages/components` contains React components that
|
||||
can be passed squiggle strings as props, and return a presentation of the result
|
||||
of the calculation.
|
||||
|
||||
`@squiggle/playground` in `packages/playground` contains a website for a playground
|
||||
`@quri/playground` in `packages/playground` contains a website for a playground
|
||||
for squiggle. This website is hosted at `playground.squiggle-language.com`
|
||||
|
||||
`@squiggle/website` in `packages/website` The main descriptive website for squiggle,
|
||||
`@quri/squiggle-website` in `packages/website` The main descriptive website for squiggle,
|
||||
it is hosted at `squiggle-language.com`.
|
||||
|
||||
The playground depends on the components library which then depends on the language.
|
||||
|
@ -24,16 +24,12 @@ This means that if you wish to work on the components library, you will need
|
|||
to package the language, and for the playground to work, you will need to package
|
||||
the components library and the playground.
|
||||
|
||||
Scripts are available for you in the root directory to do important activities,
|
||||
such as:
|
||||
# Develop
|
||||
|
||||
- `yarn build:lang`. Builds and packages the language
|
||||
- `yarn storybook:components`. Hosts the component storybook
|
||||
|
||||
# Local playground
|
||||
For any project in the repo, begin by running `yarn` in the top level
|
||||
|
||||
``` sh
|
||||
yarn build:playground
|
||||
cd packages/playground
|
||||
yarn parcel
|
||||
yarn
|
||||
```
|
||||
|
||||
See `packages/*/README.md` to work with whatever project you're interested in.
|
||||
|
|
|
@ -9,7 +9,8 @@
|
|||
"build:playground": "cd packages/playground && yarn && yarn parcel-build",
|
||||
"ci:lang": "yarn workspace @quri/squiggle-lang ci",
|
||||
"ci:components": "yarn ci:lang && yarn workspace @quri/squiggle-components ci",
|
||||
"ci:playground": "yarn ci:components && yarn workspace @quri/squiggle-playground ci"
|
||||
"ci:playground": "yarn ci:components && yarn workspace @quri/squiggle-playground ci",
|
||||
"nodeclean": "rm -r node_modules && rm -r packages/*/node_modules && "
|
||||
},
|
||||
"workspaces": [
|
||||
"packages/*"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# Squiggle Components
|
||||
This package contains all the components for squiggle. These can be used either as a library or hosted as a [storybook](https://storybook.js.org/).
|
||||
# Build for development
|
||||
|
||||
# Build for development
|
||||
You need to _prepare_ by building and bundling `squiggle-lang`
|
||||
``` sh
|
||||
cd ../squiggle-language
|
||||
|
|
|
@ -1,9 +1,11 @@
|
|||
# TODO: REVIVE PLAYGROUND.
|
||||
|
||||
# Squiggle Playground
|
||||
|
||||
This repository contains the squiggle playground, a small web interface
|
||||
for playing around with squiggle concepts.
|
||||
|
||||
It depends on `@squiggle/components` and `@squiggle/lang` so both of them will
|
||||
It depends on `@quri/squiggle-components` and `@quri/squiggle-lang` so both of them will
|
||||
need to be packaged for this to work. This can be done from the root directory
|
||||
with
|
||||
|
||||
|
|
|
@ -1,9 +1,27 @@
|
|||
# Squiggle language
|
||||
|
||||
# Build for development
|
||||
``` sh
|
||||
yarn
|
||||
yarn build
|
||||
yarn bundle
|
||||
```
|
||||
|
||||
Other:
|
||||
``` sh
|
||||
yarn start # listens to files and recompiles at every mutation
|
||||
yarn test
|
||||
yarn test:watch # keeps an active session and runs all tests at every mutation
|
||||
```
|
||||
|
||||
# TODO: clean up this README.md
|
||||
|
||||
# Squiggle Language
|
||||
Squiggle is a language for representing probability distributions, as well as
|
||||
functions that return probability distributions. Its original intended use is
|
||||
for improving epistemics around EA decisions.
|
||||
|
||||
This package, @squiggle/lang, contains the core language of squiggle. The main
|
||||
This package, @quri/squiggle-lang, contains the core language of squiggle. The main
|
||||
feature revolves around evaluating squiggle expressions. Currently the package
|
||||
only exports a single function, named "run", which from a squiggle string returns
|
||||
an object representing the result of the evaluation.
|
||||
|
|
|
@ -8,11 +8,8 @@
|
|||
"start": "rescript build -w -with-deps",
|
||||
"clean": "rescript clean",
|
||||
"test": "jest",
|
||||
"test:ci": "yarn jest ./__tests__/Lodash__test.res",
|
||||
"watch:test": "jest --watchAll",
|
||||
"watch:s": "yarn jest -- Converter_test --watch",
|
||||
"package": "tsc",
|
||||
"ci": "yarn build && yarn package"
|
||||
"test:watch": "jest --watchAll",
|
||||
"all": "yarn build && yarn bundle && yarn test"
|
||||
},
|
||||
"keywords": [
|
||||
"Rescript"
|
||||
|
|
|
@ -4,38 +4,32 @@ This website is built using [Docusaurus 2](https://docusaurus.io/), a modern sta
|
|||
|
||||
### Installation
|
||||
|
||||
```
|
||||
$ yarn
|
||||
``` sh
|
||||
yarn
|
||||
```
|
||||
|
||||
### Local Development
|
||||
|
||||
```
|
||||
$ yarn start
|
||||
``` sh
|
||||
yarn start
|
||||
```
|
||||
|
||||
This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
|
||||
|
||||
### Build
|
||||
|
||||
```
|
||||
$ yarn build
|
||||
``` sh
|
||||
yarn build
|
||||
```
|
||||
|
||||
This command generates static content into the `build` directory and can be served using any static contents hosting service.
|
||||
|
||||
### Deployment
|
||||
### Clean
|
||||
|
||||
Using SSH:
|
||||
|
||||
```
|
||||
$ USE_SSH=true yarn deploy
|
||||
Clean up the build artefacts.
|
||||
``` sh
|
||||
yarn clean
|
||||
```
|
||||
|
||||
Not using SSH:
|
||||
|
||||
```
|
||||
$ GIT_USER=<Your GitHub username> yarn deploy
|
||||
```
|
||||
|
||||
If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.
|
||||
# TODO: unify formatting across `packages/*/README.md`
|
||||
# TODO: build docs in `ci.yaml`.
|
||||
|
|
|
@ -3,15 +3,10 @@
|
|||
"version": "0.0.0",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"docusaurus": "docusaurus",
|
||||
"start": "docusaurus start",
|
||||
"build": "docusaurus build",
|
||||
"swizzle": "docusaurus swizzle",
|
||||
"deploy": "docusaurus deploy",
|
||||
"clear": "docusaurus clear",
|
||||
"serve": "docusaurus serve",
|
||||
"write-translations": "docusaurus write-translations",
|
||||
"write-heading-ids": "docusaurus write-heading-ids"
|
||||
"clean": "docusaurus clear",
|
||||
"all": "yarn build"
|
||||
},
|
||||
"dependencies": {
|
||||
"@docusaurus/core": "2.0.0-beta.15",
|
||||
|
|
Loading…
Reference in New Issue
Block a user