forked from Codility/viz-multiple_value-marketplace
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: setup ci & release workflows, update readme
Changelog: - [ ] Setup CI and release workflows - [ ] Changes output directory to dist/ - [ ] Updates README with new instructions - [ ] Deletes build artifacts.
- Loading branch information
Showing
8 changed files
with
62 additions
and
137 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
name: ci-workflow | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
ci-build-job: | ||
uses: looker-open-source/reusable-actions/.github/workflows/marketplace-viz-ci-build.yml@main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: ci-release-workflow | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
workflow_dispatch: | ||
|
||
# Cancels any release workflows in progress | ||
concurrency: | ||
group: ${{ github.workflow }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
ci-release-job: | ||
permissions: | ||
contents: write | ||
pull-requests: write | ||
uses: looker-open-source/reusable-actions/.github/workflows/marketplace-viz-release.yml@main | ||
# Inherits the Looker Automation Bot token to create release PRs and releases | ||
secrets: inherit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
node_modules/ | ||
.DS_STORE | ||
yarn-error.log | ||
dist/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
yarn run format && yarn run test && yarn run build | ||
yarn run format && yarn run test && yarn run build:legacy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,72 +1,42 @@ | ||
# Multiple Value Visualization | ||
|
||
### What if I find an error? Suggestions for improvements? | ||
### What if I find an error or want to suggest improvements? | ||
|
||
Great! Marketplace content -- including visualizations -- were designed for continuous improvement through the help of the entire Looker community and we'd love your input. To report an error or improvement recommendation, please get in touch at help.looker.com to submit a request. Please be as detailed as possible in your explanation and we'll address it as quick as we can. | ||
We welcome your contributions to this open source visualization with a pull request. Please reach out to Google Cloud support to report an error or suggest an improvement. You can also extend this visualization for your own use case. | ||
|
||
### Interested in extending the visualization for your own use case? | ||
### Local development | ||
|
||
#### Quickstart Dev Instructions | ||
You must have Node v16 and `yarn` installed. | ||
|
||
1. **Install Dependecies.** | ||
#### Install Dependencies | ||
|
||
Using yarn, install all dependencies and the git hooks to ensure code | ||
quality using: | ||
Call `yarn` to install all dependencies, includes React. | ||
|
||
``` | ||
yarn | ||
``` | ||
``` | ||
yarn | ||
``` | ||
|
||
2. ** Install all the git hooks to ensure code quality using** | ||
#### Build javascript | ||
|
||
``` | ||
yarn prepare | ||
``` | ||
Run `yarn build` to bundle the javascript. The resulting minified bundle.js will be in the `dist` directory. | ||
|
||
3. **Make changes to the source code** | ||
``` | ||
yarn build | ||
``` | ||
|
||
4. **Compile your code** | ||
#### Local testing and other commands | ||
|
||
You need to compile your react code, let's run: | ||
Check package.json for additional commands. | ||
|
||
``` | ||
yarn build | ||
``` | ||
#### Commit title format | ||
|
||
Recommended: Webpack can detect changes and build automatically | ||
Commit titles on `master` branch follow [Conventional Commit](https://www.conventionalcommits.org/en/v1.0.0/#summary) message spec. Your commit title must prefix one of 3 types and an optional `!` with the format `TYPE: commit title goes here`. | ||
|
||
``` | ||
yarn watch | ||
``` | ||
- `fix` - a commit of the type fix patches a bug (correlates with PATCH in Semantic Versioning). `fix: Correct number formatting` | ||
- `feat` - a commit of the type feat introduces a new feature (correlates with MINOR in Semantic Versioning). `feat: Add column sorting` | ||
- `chore` - a commit of the type chore does not affect viz functionality (corresponds with no change in Semantic Versioning). `chore: Update build process` | ||
- Append an `!` exclamation point to the type if it is a breaking change. `fix!: ...` | ||
|
||
Your compiled code can be found in this repo. | ||
#### Release management | ||
|
||
5. **Running unit tests** | ||
```shell | ||
yarn test | ||
``` | ||
or | ||
```shell | ||
bin/test | ||
``` | ||
**`multiple_value.js`**: This visualization's minified distribution file. | ||
**`LICENSE`**: Looker's Marketplace content License file. | ||
**`manifest.lkml`**: Looker's external dependencies configuration file. The visualization object is defined here. | ||
**`marketplace.json`**: A JSON file containing information the marketplace installer uses to set up this project. | ||
**`/src`**: This directory will contain all of the visualization's source code. | ||
**`/node_modules`**: The directory where all of the modules of code that your project depends on (npm packages) are automatically installed. | ||
**`README.md`**: This! A text file containing useful reference information about this visualization. | ||
**`yarn.lock`**: [Yarn](https://yarnpkg.com/) is a package manager alternative to npm. This file serves essentially the same purpose as `package-lock.json`, just for a different package management system. | ||
**`.babelrc`**: A configuration file for the Babel jsx -> js compiler. | ||
This repo uses GitHub workflows with [release-please](https://github.com/googleapis/release-please) [action](https://github.com/google-github-actions/release-please-action) to create Github releases, determine versioning, and generate changelogs. |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters