diff --git a/.dockerignore b/.dockerignore index 32158cd9b..fb5a407e9 100644 --- a/.dockerignore +++ b/.dockerignore @@ -16,3 +16,48 @@ out/ **/out/ dist/ **/dist/ +# Logs +npm-debug.log* +pnpm-debug.log* +.pnpm-debug.log* +yarn-debug.log* +yarn-error.log* + +# OS junk +.DS_Store +Thumbs.db + +# Editor settings +.vscode +.idea + +# Coverage and test output +coverage/ +**/coverage/ +*.lcov +.junit/ +test-results/ + +# Caches and build artifacts +.cache/ +**/.cache/ +storybook-static/ +*storybook.log +*.tsbuildinfo + +# Local env and secrets +.env.local +.env.development.local +.env.test.local +.env.production.local +.secrets +tmp/ +temp/ + +# Database/cache dumps +*.rdb +*.rdb.gz + +# Misc +*.pem +*.key diff --git a/.github/workflows/build-branch.yml b/.github/workflows/build-branch.yml index acd9348d2..087a012d4 100644 --- a/.github/workflows/build-branch.yml +++ b/.github/workflows/build-branch.yml @@ -35,6 +35,10 @@ on: - preview - canary +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + env: TARGET_BRANCH: ${{ github.ref_name }} ARM64_BUILD: ${{ github.event.inputs.arm64 }} @@ -268,15 +272,14 @@ jobs: if: ${{ needs.branch_build_setup.outputs.aio_build == 'true' }} name: Build-Push AIO Docker Image runs-on: ubuntu-22.04 - needs: [ - branch_build_setup, - branch_build_push_admin, - branch_build_push_web, - branch_build_push_space, - branch_build_push_live, - branch_build_push_api, - branch_build_push_proxy - ] + needs: + - branch_build_setup + - branch_build_push_admin + - branch_build_push_web + - branch_build_push_space + - branch_build_push_live + - branch_build_push_api + - branch_build_push_proxy steps: - name: Checkout Files uses: actions/checkout@v4 @@ -285,7 +288,7 @@ jobs: id: prepare_aio_assets run: | cd deployments/aio/community - + if [ "${{ needs.branch_build_setup.outputs.build_type }}" == "Release" ]; then aio_version=${{ needs.branch_build_setup.outputs.release_version }} else @@ -324,7 +327,14 @@ jobs: upload_build_assets: name: Upload Build Assets runs-on: ubuntu-22.04 - needs: [branch_build_setup, branch_build_push_admin, branch_build_push_web, branch_build_push_space, branch_build_push_live, branch_build_push_api, branch_build_push_proxy] + needs: + - branch_build_setup + - branch_build_push_admin + - branch_build_push_web + - branch_build_push_space + - branch_build_push_live + - branch_build_push_api + - branch_build_push_proxy steps: - name: Checkout Files uses: actions/checkout@v4 @@ -397,4 +407,3 @@ jobs: ${{ github.workspace }}/deployments/cli/community/docker-compose.yml ${{ github.workspace }}/deployments/cli/community/variables.env ${{ github.workspace }}/deployments/swarm/community/swarm.sh - diff --git a/.github/workflows/build-test-pull-request.yml b/.github/workflows/build-test-pull-request.yml deleted file mode 100644 index acbd9d26e..000000000 --- a/.github/workflows/build-test-pull-request.yml +++ /dev/null @@ -1,95 +0,0 @@ -name: Build and Lint on Pull Request - -on: - workflow_dispatch: - pull_request: - types: ["opened", "synchronize", "ready_for_review"] - -jobs: - lint-server: - if: github.event.pull_request.draft == false - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: "3.x" # Specify the Python version you need - - name: Install Pylint - run: python -m pip install ruff - - name: Install Server Dependencies - run: cd apps/server && pip install -r requirements.txt - - name: Lint apps/server - run: ruff check --fix apps/server - - lint-admin: - if: github.event.pull_request.draft == false - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: 20.x - - run: yarn install - - run: yarn lint --filter=admin - - lint-space: - if: github.event.pull_request.draft == false - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: 20.x - - run: yarn install - - run: yarn lint --filter=space - - lint-web: - if: github.event.pull_request.draft == false - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: 20.x - - run: yarn install - - run: yarn lint --filter=web - - build-admin: - needs: lint-admin - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: 20.x - - run: yarn install - - run: yarn build --filter=admin - - build-space: - needs: lint-space - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: 20.x - - run: yarn install - - run: yarn build --filter=space - - build-web: - needs: lint-web - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: 20.x - - run: yarn install - - run: yarn build --filter=web diff --git a/.github/workflows/check-version.yml b/.github/workflows/check-version.yml index ca8b6f8b3..855ee359f 100644 --- a/.github/workflows/check-version.yml +++ b/.github/workflows/check-version.yml @@ -17,8 +17,6 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 - with: - node-version: '18' - name: Get PR Branch version run: echo "PR_VERSION=$(node -p "require('./package.json').version")" >> $GITHUB_ENV diff --git a/.github/workflows/pull-request-build-lint-api.yml b/.github/workflows/pull-request-build-lint-api.yml new file mode 100644 index 000000000..50d105ef5 --- /dev/null +++ b/.github/workflows/pull-request-build-lint-api.yml @@ -0,0 +1,40 @@ +name: Build and lint API + +on: + workflow_dispatch: + pull_request: + branches: + - "preview" + types: + - "opened" + - "synchronize" + - "ready_for_review" + - "review_requested" + - "reopened" + paths: + - "apps/api/**" + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + lint-api: + name: Lint API + runs-on: ubuntu-latest + timeout-minutes: 25 + if: | + github.event.pull_request.draft == false && + github.event.pull_request.requested_reviewers != null + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.x" + - name: Install Pylint + run: python -m pip install ruff + - name: Install API Dependencies + run: cd apps/api && pip install -r requirements.txt + - name: Lint apps/api + run: ruff check --fix apps/api diff --git a/.github/workflows/pull-request-build-lint-web-apps.yml b/.github/workflows/pull-request-build-lint-web-apps.yml new file mode 100644 index 000000000..435ec2093 --- /dev/null +++ b/.github/workflows/pull-request-build-lint-web-apps.yml @@ -0,0 +1,53 @@ +name: Build and lint web apps + +on: + workflow_dispatch: + pull_request: + branches: + - "preview" + types: + - "opened" + - "synchronize" + - "ready_for_review" + - "review_requested" + - "reopened" + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + build-and-lint: + name: Build and lint web apps + runs-on: ubuntu-latest + timeout-minutes: 25 + if: | + github.event.pull_request.draft == false && + github.event.pull_request.requested_reviewers != null + env: + TURBO_SCM_BASE: ${{ github.event.pull_request.base.sha }} + TURBO_SCM_HEAD: ${{ github.sha }} + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + fetch-depth: 50 + filter: blob:none + + - name: Set up Node.js + uses: actions/setup-node@v4 + + - name: Enable Corepack and pnpm + run: corepack enable pnpm + + - name: Install dependencies + run: pnpm install --frozen-lockfile + + - name: Lint Affected + run: pnpm turbo run check:lint --affected + + - name: Check Affected format + run: pnpm turbo run check:format --affected + + - name: Build Affected + run: pnpm turbo run build --affected diff --git a/.gitignore b/.gitignore index a6a407ba9..4baa3495a 100644 --- a/.gitignore +++ b/.gitignore @@ -24,11 +24,13 @@ out/ .DS_Store *.pem .history +tsconfig.tsbuildinfo # Debug npm-debug.log* yarn-debug.log* yarn-error.log* +pnpm-debug.log* .pnpm-debug.log* # Local env files @@ -60,6 +62,7 @@ node_modules/ assets/dist/ npm-debug.log yarn-error.log +pnpm-debug.log # Editor directories and files .idea @@ -75,10 +78,9 @@ package-lock.json # lock files package-lock.json -pnpm-lock.yaml -pnpm-workspace.yaml -.npmrc + + .secrets tmp/ @@ -95,3 +97,5 @@ dev-editor # Redis *.rdb *.rdb.gz + +storybook-static diff --git a/.npmrc b/.npmrc new file mode 100644 index 000000000..d652acc3b --- /dev/null +++ b/.npmrc @@ -0,0 +1,34 @@ +# Enforce pnpm workspace behavior and allow Turbo's lifecycle hooks if scripts are disabled +# This repo uses pnpm with workspaces. + +# Prefer linking local workspace packages when available +prefer-workspace-packages=true +link-workspace-packages=true +shared-workspace-lockfile=true + +# Make peer installs smoother across the monorepo +auto-install-peers=true +strict-peer-dependencies=false + +# If scripts are disabled (e.g., CI with --ignore-scripts), allowlisted packages can still run their hooks +# Turbo occasionally performs postinstall tasks for optimal performance +# moved to pnpm-workspace.yaml: onlyBuiltDependencies (e.g., allow turbo) + +public-hoist-pattern[]=*eslint* +public-hoist-pattern[]=prettier +public-hoist-pattern[]=typescript + +# Reproducible installs across CI and dev +prefer-frozen-lockfile=true + +# Prefer resolving to highest versions in monorepo to reduce duplication +resolution-mode=highest + +# Speed up native module builds by caching side effects +side-effects-cache=true + +# Speed up local dev by reusing local store when possible +prefer-offline=true + +# Ensure workspace protocol is used when adding internal deps +save-workspace-protocol=true diff --git a/.yarnrc.yml b/.yarnrc.yml deleted file mode 100644 index 3186f3f07..000000000 --- a/.yarnrc.yml +++ /dev/null @@ -1 +0,0 @@ -nodeLinker: node-modules diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c401c3c2c..39eb4e800 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -73,7 +73,7 @@ docker compose -f docker-compose-local.yml up 4. Start web apps: ```bash -yarn dev +pnpm dev ``` 5. Open your browser to http://localhost:3001/god-mode/ and register yourself as instance admin diff --git a/README.md b/README.md index da57f38d8..f6b364bef 100644 --- a/README.md +++ b/README.md @@ -2,11 +2,10 @@
-Open-source project management that unlocks customer value
+Modern project management for all teams
@@ -25,14 +24,7 @@
+
-
-
+
+
-
-
- Configure instance-wide settings to secure your instance
-
-
-
-
@@ -48,13 +40,13 @@ Meet [Plane](https://plane.so/), an open-source project management tool to track
Getting started with Plane is simple. Choose the setup that works best for you:
- **Plane Cloud**
-Sign up for a free account on [Plane Cloud](https://app.plane.so)—it's the fastest way to get up and running without worrying about infrastructure.
+ Sign up for a free account on [Plane Cloud](https://app.plane.so)—it's the fastest way to get up and running without worrying about infrastructure.
- **Self-host Plane**
-Prefer full control over your data and infrastructure? Install and run Plane on your own servers. Follow our detailed [deployment guides](https://developers.plane.so/self-hosting/overview) to get started.
+ Prefer full control over your data and infrastructure? Install and run Plane on your own servers. Follow our detailed [deployment guides](https://developers.plane.so/self-hosting/overview) to get started.
-| Installation methods | Docs link |
-| -------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| Installation methods | Docs link |
+| -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Docker | [](https://developers.plane.so/self-hosting/methods/docker-compose) |
| Kubernetes | [](https://developers.plane.so/self-hosting/methods/kubernetes) |
@@ -63,58 +55,58 @@ Prefer full control over your data and infrastructure? Install and run Plane on
## 🌟 Features
- **Issues**
-Efficiently create and manage tasks with a robust rich text editor that supports file uploads. Enhance organization and tracking by adding sub-properties and referencing related issues.
+ Efficiently create and manage tasks with a robust rich text editor that supports file uploads. Enhance organization and tracking by adding sub-properties and referencing related issues.
- **Cycles**
-Maintain your team’s momentum with Cycles. Track progress effortlessly using burn-down charts and other insightful tools.
+ Maintain your team’s momentum with Cycles. Track progress effortlessly using burn-down charts and other insightful tools.
- **Modules**
-Simplify complex projects by dividing them into smaller, manageable modules.
+ Simplify complex projects by dividing them into smaller, manageable modules.
- **Views**
-Customize your workflow by creating filters to display only the most relevant issues. Save and share these views with ease.
+ Customize your workflow by creating filters to display only the most relevant issues. Save and share these views with ease.
- **Pages**
-Capture and organize ideas using Plane Pages, complete with AI capabilities and a rich text editor. Format text, insert images, add hyperlinks, or convert your notes into actionable items.
+ Capture and organize ideas using Plane Pages, complete with AI capabilities and a rich text editor. Format text, insert images, add hyperlinks, or convert your notes into actionable items.
- **Analytics**
-Access real-time insights across all your Plane data. Visualize trends, remove blockers, and keep your projects moving forward.
+ Access real-time insights across all your Plane data. Visualize trends, remove blockers, and keep your projects moving forward.
- **Drive** (_coming soon_): The drive helps you share documents, images, videos, or any other files that make sense to you or your team and align on the problem/solution.
-
## 🛠️ Local development
See [CONTRIBUTING](./CONTRIBUTING.md)
## ⚙️ Built with
+
[](https://nextjs.org/)
[](https://www.djangoproject.com/)
[](https://nodejs.org/en)
## 📸 Screenshots
-
-
-
+
+
@@ -123,7 +115,7 @@ See [CONTRIBUTING](./CONTRIBUTING.md)
@@ -132,25 +124,16 @@ See [CONTRIBUTING](./CONTRIBUTING.md)
-
-
-
## License
+
This project is licensed under the [GNU Affero General Public License v3.0](https://github.com/makeplane/plane/blob/master/LICENSE.txt).
diff --git a/apps/admin/.eslintignore b/apps/admin/.eslintignore
new file mode 100644
index 000000000..27e50ad7c
--- /dev/null
+++ b/apps/admin/.eslintignore
@@ -0,0 +1,12 @@
+.next/*
+out/*
+public/*
+dist/*
+node_modules/*
+.turbo/*
+.env*
+.env
+.env.local
+.env.development
+.env.production
+.env.test
\ No newline at end of file
diff --git a/apps/admin/.eslintrc.js b/apps/admin/.eslintrc.js
index 666f5ab50..1662fabf7 100644
--- a/apps/admin/.eslintrc.js
+++ b/apps/admin/.eslintrc.js
@@ -1,5 +1,4 @@
module.exports = {
root: true,
extends: ["@plane/eslint-config/next.js"],
- parser: "@typescript-eslint/parser",
};
diff --git a/apps/admin/.prettierignore b/apps/admin/.prettierignore
index 43e8a7b8f..3cd6b08a0 100644
--- a/apps/admin/.prettierignore
+++ b/apps/admin/.prettierignore
@@ -2,5 +2,5 @@
.vercel
.tubro
out/
-dis/
-build/
\ No newline at end of file
+dist/
+build/
diff --git a/apps/admin/Dockerfile.admin b/apps/admin/Dockerfile.admin
index 01884206e..6bfa0765f 100644
--- a/apps/admin/Dockerfile.admin
+++ b/apps/admin/Dockerfile.admin
@@ -1,5 +1,11 @@
+# syntax=docker/dockerfile:1.7
FROM node:22-alpine AS base
+# Setup pnpm package manager with corepack and configure global bin directory for caching
+ENV PNPM_HOME="/pnpm"
+ENV PATH="$PNPM_HOME:$PATH"
+RUN corepack enable
+
# *****************************************************************************
# STAGE 1: Build the project
# *****************************************************************************
@@ -7,7 +13,8 @@ FROM base AS builder
RUN apk add --no-cache libc6-compat
WORKDIR /app
-RUN yarn global add turbo
+ARG TURBO_VERSION=2.5.6
+RUN corepack enable pnpm && pnpm add -g turbo@${TURBO_VERSION}
COPY . .
RUN turbo prune --scope=admin --docker
@@ -22,11 +29,13 @@ WORKDIR /app
COPY .gitignore .gitignore
COPY --from=builder /app/out/json/ .
-COPY --from=builder /app/out/yarn.lock ./yarn.lock
-RUN yarn install --network-timeout 500000
+COPY --from=builder /app/out/pnpm-lock.yaml ./pnpm-lock.yaml
+RUN corepack enable pnpm
+RUN --mount=type=cache,id=pnpm-store,target=/pnpm/store pnpm fetch --store-dir=/pnpm/store
COPY --from=builder /app/out/full/ .
COPY turbo.json turbo.json
+RUN --mount=type=cache,id=pnpm-store,target=/pnpm/store pnpm install --offline --frozen-lockfile --store-dir=/pnpm/store
ARG NEXT_PUBLIC_API_BASE_URL=""
ENV NEXT_PUBLIC_API_BASE_URL=$NEXT_PUBLIC_API_BASE_URL
@@ -49,7 +58,7 @@ ENV NEXT_PUBLIC_WEB_BASE_URL=$NEXT_PUBLIC_WEB_BASE_URL
ENV NEXT_TELEMETRY_DISABLED=1
ENV TURBO_TELEMETRY_DISABLED=1
-RUN yarn turbo run build --filter=admin
+RUN pnpm turbo run build --filter=admin
# *****************************************************************************
# STAGE 3: Copy the project and start it
@@ -91,4 +100,4 @@ ENV TURBO_TELEMETRY_DISABLED=1
EXPOSE 3000
-CMD ["node", "apps/admin/server.js"]
\ No newline at end of file
+CMD ["node", "apps/admin/server.js"]
diff --git a/apps/admin/Dockerfile.dev b/apps/admin/Dockerfile.dev
index edf82d227..0b82669c4 100644
--- a/apps/admin/Dockerfile.dev
+++ b/apps/admin/Dockerfile.dev
@@ -5,8 +5,8 @@ WORKDIR /app
COPY . .
-RUN yarn global add turbo
-RUN yarn install
+RUN corepack enable pnpm && pnpm add -g turbo
+RUN pnpm install
ENV NEXT_PUBLIC_ADMIN_BASE_PATH="/god-mode"
@@ -14,4 +14,4 @@ EXPOSE 3000
VOLUME [ "/app/node_modules", "/app/admin/node_modules" ]
-CMD ["yarn", "dev", "--filter=admin"]
+CMD ["pnpm", "dev", "--filter=admin"]
diff --git a/apps/admin/app/(all)/(dashboard)/authentication/gitlab/page.tsx b/apps/admin/app/(all)/(dashboard)/authentication/gitlab/page.tsx
index cdcfcd61b..f0b464acb 100644
--- a/apps/admin/app/(all)/(dashboard)/authentication/gitlab/page.tsx
+++ b/apps/admin/app/(all)/(dashboard)/authentication/gitlab/page.tsx
@@ -66,9 +66,11 @@ const InstanceGitlabAuthenticationPage = observer(() => {
- Manage your Plane instance
-
-