Skip to content

Commit

Permalink
Merge branch 'main' into felicio/changeset-check
Browse files Browse the repository at this point in the history
  • Loading branch information
felicio authored Jan 7, 2025
2 parents 8ecea95 + 1274bd9 commit ac5f149
Show file tree
Hide file tree
Showing 122 changed files with 21,658 additions and 20,752 deletions.
6 changes: 0 additions & 6 deletions .eslintignore

This file was deleted.

29 changes: 17 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,31 +20,36 @@ jobs:

steps:
- name: Check out code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
# https://github.com/changesets/changesets/issues/1055
fetch-depth: 0

- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: 9.12.3

- name: Setup Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 18
cache: 'yarn'
node-version: 20.18.0
cache: 'pnpm'

- name: Changeset
run: pnpm dlx changeset status --since origin/main

- name: Install dependencies
run: yarn --frozen-lockfile
run: pnpm install --frozen-lockfile

- name: Build
run: yarn build
run: pnpm build

- name: Typecheck
run: yarn typecheck
run: pnpm typecheck

- name: Lint
run: yarn lint && yarn format --check
run: pnpm lint && pnpm format --check

- name: Test
run: yarn test

- name: Changeset
run: yarn changeset status --since origin/main
run: pnpm test
17 changes: 10 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,19 +20,22 @@ jobs:
needs: ci
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
node-version: 18
- run: yarn install --frozen-lockfile
- run: yarn build
version: 9.12.3
- uses: actions/setup-node@v4
with:
node-version: 20.18.0
- run: pnpm install --frozen-lockfile
- run: pnpm build
- uses: changesets/action@v1
id: changesets
with:
title: Release
commit: Release
version: yarn changeset version
publish: yarn changeset publish
version: pnpm changeset version
publish: pnpm changeset publish
createGithubReleases: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx lint-staged
pnpm lint-staged
1 change: 1 addition & 0 deletions .node-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
20.18.0
2 changes: 2 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
!.npmrc
#!pnpm-lock.yaml
11 changes: 11 additions & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
; https://pnpm.io/cli/run#enable-pre-post-scripts
enable-pre-post-scripts=true
; https://pnpm.io/npmrc#node-linker
; node-linker=hoisted
; https://pnpm.io/npmrc#shamefully-hoist
;shamefully-hoist=true
;auto-install-peers=true
; https://pnpm.io/npmrc#node-version
node-version=20.18.0
; https://pnpm.io/npmrc#engine-strict
engine-strict=true
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
pnpm-lock.yaml
8 changes: 7 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
{
"typescript.tsdk": "node_modules/typescript/lib",
"npm.packageManager": "yarn",
"npm.packageManager": "pnpm",
"eslint.useESLintClass": true,
"eslint.workingDirectories": [
"./packages/colors",
"./packages/icons",
"./packages/components",
"./packages/status-js",
"./apps/connector",
{
"mode": "auto",
"#comment": "See https://github.com/microsoft/vscode-eslint/issues/1161 for reason (i.e. multiple .eslintrc config files)"
Expand Down
28 changes: 14 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ This monorepo contains packages for building web applications in the Status ecos

## Packages

| Name | `npm` | Description |
| ------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [`@status-im/components`](./packages/components) | [![npm version](https://img.shields.io/npm/v/@status-im/components)](https://www.npmjs.com/package/@status-im/components) | Component library built with Radix UI, React Aria, Tailwind CSS. |
| [`@status-im/js`](./packages/status-js) | [![npm version](https://img.shields.io/npm/v/@status-im/js)](https://www.npmjs.com/package/@status-im/js) | Libary for Waku protocol integration and blockchain interactions. |
| [`@status-im/icons`](./packages/icons) | [![npm version](https://img.shields.io/npm/v/@status-im/icons)](https://www.npmjs.com/package/@status-im/icons) | Auto-generated icon library based on our [design system](https://www.figma.com/design/qLLuMLfpGxK9OfpIavwsmK/Iconset?node-id=3239-987&node-type=frame&t=0h8iIiZ3Sf0g4MRV-11). |
| [`@status-im/colors`](./packages/colors) | [![npm version](https://img.shields.io/npm/v/@status-im/colors.svg)](https://www.npmjs.com/package/@status-im/colors) | Auto-generated color palette based on our [design system](https://www.figma.com/design/v98g9ZiaSHYUdKWrbFg9eM/Foundations?node-id=619-5995&node-type=canvas&m=dev). |
| [`@status-im/eslint-config`](./packages/eslint-config) | | Shared ESLint configuration for consistent code style across projects. |
| Name | `npm` | Description |
| ------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [`@status-im/components`](./packages/components) | [![npm version](https://img.shields.io/npm/v/@status-im/components)](https://www.npmjs.com/package/@status-im/components) | Component library built with Radix UI, React Aria, Tailwind CSS. |
| [`@status-im/js`](./packages/status-js) | [![npm version](https://img.shields.io/npm/v/@status-im/js)](https://www.npmjs.com/package/@status-im/js) | Libary for Waku protocol integration and blockchain interactions. |
| [`@status-im/icons`](./packages/icons) | [![npm version](https://img.shields.io/npm/v/@status-im/icons)](https://www.npmjs.com/package/@status-im/icons) | Auto-generated icon library based on our [design system](https://www.figma.com/design/qLLuMLfpGxK9OfpIavwsmK/Iconset?node-id=3239-987&node-type=frame&t=0h8iIiZ3Sf0g4MRV-11). |
| [`@status-im/colors`](./packages/colors) | [![npm version](https://img.shields.io/npm/v/@status-im/colors.svg)](https://www.npmjs.com/package/@status-im/colors) | Auto-generated color palette based on our [design system](https://www.figma.com/design/v98g9ZiaSHYUdKWrbFg9eM/Foundations?node-id=619-5995&node-type=canvas&m=dev). |
| [`@status-im/eslint-config`](./packages/eslint-config) | [![npm version](https://img.shields.io/npm/v/@status-im/eslint-config.svg)](https://www.npmjs.com/package/@status-im/eslint-config) | Shared ESLint configuration for consistent code style across projects. |

## Apps

Expand All @@ -24,8 +24,8 @@ This monorepo contains packages for building web applications in the Status ecos

Required:

- **[Node.js](https://nodejs.org/)** v18.x
- **[Yarn](https://yarnpkg.com/)** v1.22.x
- **[Node.js](https://nodejs.org/)** v20.x
- **[pnpm](https://pnpm.io)** v9.12.x

Recommended:

Expand Down Expand Up @@ -57,32 +57,32 @@ Recommended:
2. Install dependencies:

```
yarn install
pnpm install
```

3. Build all packages:

```
yarn build
pnpm build
```

4. Run tests:

```
yarn test
pnpm test
```

5. Start development mode:
```
yarn dev
pnpm dev
```

## Storybook

To view and interact with the components, you can run Storybook:

```
yarn storybook
pnpm storybook
```

This will start the Storybook server, allowing you to browse and test components in isolation.
Expand Down
39 changes: 0 additions & 39 deletions apps/connector/.eslintrc.js

This file was deleted.

9 changes: 9 additions & 0 deletions apps/connector/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# connector

## 0.0.2

### Patch Changes

- 3c71b8c: update ESLint
- Updated dependencies [3c71b8c]
- @status-im/colors@1.0.2
50 changes: 45 additions & 5 deletions apps/connector/Jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#!/usr/bin/env groovy
library '[email protected]'

def changesDetected = false

pipeline {
agent { label 'linux' }

Expand All @@ -27,12 +29,26 @@ pipeline {
}

stages {
stage('Check Changed Files') {
when {
changeset pattern: "apps/connector/**", comparator: "GLOB"
}
steps {
script {
changesDetected = true
}
}
}

stage('Install') {
when {
expression { changesDetected }
}
steps {
dir("${env.WORKSPACE}/apps/connector") {
script {
nix.shell(
'yarn install --frozen-lockfile',
'pnpm install --frozen-lockfile',
pure: false,
entryPoint: "${env.WORKSPACE}/apps/connector/shell.nix"
)
Expand All @@ -42,11 +58,14 @@ pipeline {
}

stage('Build') {
when {
expression { changesDetected }
}
steps {
dir("${env.WORKSPACE}/apps/connector") {
dir("${env.WORKSPACE}") {
script {
nix.shell(
'yarn build:chrome',
'pnpm turbo run build --filter=connector',
pure: false,
entryPoint: "${env.WORKSPACE}/apps/connector/shell.nix"
)
Expand All @@ -56,6 +75,9 @@ pipeline {
}

stage('Zip') {
when {
expression { changesDetected }
}
steps {
dir("${env.WORKSPACE}/apps/connector") {
zip(
Expand All @@ -68,6 +90,9 @@ pipeline {
}

stage('Archive') {
when {
expression { changesDetected }
}
steps {
dir("${env.WORKSPACE}/apps/connector") {
archiveArtifacts(
Expand All @@ -79,6 +104,9 @@ pipeline {
}

stage('Upload') {
when {
expression { changesDetected }
}
steps {
dir("${env.WORKSPACE}/apps/connector") {
script {
Expand All @@ -90,8 +118,20 @@ pipeline {
}

post {
success { script { github.notifyPR(true) } }
failure { script { github.notifyPR(false) } }
success {
script {
if(changesDetected) {
github.notifyPR(true)
}
}
}
failure {
script {
if(changesDetected) {
github.notifyPR(false)
}
}
}
cleanup { cleanWs() }
}
}
10 changes: 5 additions & 5 deletions apps/connector/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@ Tested with these browsers:
#### Develop

```bash
yarn dev:chrome
pnpm dev:chrome
```

#### Build

```bash
yarn build:chrome
pnpm build:chrome
```

#### Load
Expand All @@ -42,7 +42,7 @@ Google Chrome > Window > Extensions > Load unpacked > select build (build/chrome
#### Develop

```bash
yarn dev:safari
pnpm dev:safari
```

#### Convert
Expand Down Expand Up @@ -70,13 +70,13 @@ Safari > Settings... > Extensions > check Status
#### Develop

```bash
yarn dev:firefox
pnpm dev:firefox
```

#### Build

```bash
yarn build:firefox
pnpm build:firefox
```

#### Load
Expand Down
Loading

0 comments on commit ac5f149

Please sign in to comment.