mirror of
https://github.com/Shadowfita/docmost.git
synced 2025-11-22 20:51:04 +10:00
Compare commits
4 Commits
NTLM-Auth
...
15eb997c92
| Author | SHA1 | Date | |
|---|---|---|---|
| 15eb997c92 | |||
| be0d97661a | |||
| 4e2b23c97e | |||
| dc3ce27762 |
47
.github/workflows/main.yml
vendored
Normal file
47
.github/workflows/main.yml
vendored
Normal file
@ -0,0 +1,47 @@
|
||||
name: Sync Merged-Downstream with Docmost Upstream Main
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 0 * * *' # Run daily at midnight UTC
|
||||
|
||||
jobs:
|
||||
sync:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0 # Fetch all history to detect changes properly
|
||||
|
||||
- name: Set up git
|
||||
run: |
|
||||
git config --global user.name "Shadowfita"
|
||||
git config --global user.email "www.ryan.palmer@hotmail.com"
|
||||
|
||||
- name: Fetch upstream
|
||||
run: |
|
||||
git remote add upstream https://github.com/docmost/docmost.git
|
||||
git fetch upstream
|
||||
|
||||
- name: Check if upstream has changes
|
||||
id: check_changes
|
||||
run: |
|
||||
UPSTREAM_DIFF=$(git diff --name-only upstream/main)
|
||||
if [ -z "$UPSTREAM_DIFF" ]; then
|
||||
echo "No changes in upstream main branch."
|
||||
echo "::set-output name=changes::false"
|
||||
else
|
||||
echo "Changes detected in upstream main branch."
|
||||
echo "::set-output name=changes::true"
|
||||
fi
|
||||
|
||||
- name: Merge upstream/main into Merged-Downstream
|
||||
if: steps.check_changes.outputs.changes == 'true'
|
||||
run: |
|
||||
git checkout Merged-Downstream
|
||||
git merge upstream/main
|
||||
|
||||
- name: Push changes to Merged-Downstream
|
||||
if: steps.check_changes.outputs.changes == 'true'
|
||||
run: |
|
||||
git push origin Merged-Downstream
|
||||
@ -17,6 +17,7 @@ To get started with Docmost, please refer to our [documentation](https://docmost
|
||||
|
||||
## Features
|
||||
- Real-time collaboration
|
||||
- Diagrams (Draw.io, Excalidraw and Mermaid)
|
||||
- Spaces
|
||||
- Permissions management
|
||||
- Groups
|
||||
@ -32,4 +33,4 @@ To get started with Docmost, please refer to our [documentation](https://docmost
|
||||
</p>
|
||||
|
||||
### Contributing
|
||||
See the [development doc](https://docmost.com/docs/self-hosting/development)
|
||||
See the [development documentation](https://docmost.com/docs/self-hosting/development)
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "client",
|
||||
"private": true,
|
||||
"version": "0.3.0",
|
||||
"version": "0.3.1",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
"build": "tsc && vite build",
|
||||
|
||||
@ -15,15 +15,19 @@ export function getAppUrl(): string {
|
||||
}
|
||||
|
||||
export function getBackendUrl(): string {
|
||||
return getAppUrl() + "/api";
|
||||
return getAppUrl() + '/api';
|
||||
}
|
||||
|
||||
export function getCollaborationUrl(): string {
|
||||
const COLLAB_PATH = "/collab";
|
||||
const url = process.env.APP_URL || getAppUrl();
|
||||
const COLLAB_PATH = '/collab';
|
||||
|
||||
const wsProtocol = url.startsWith("https") ? "wss" : "ws";
|
||||
return `${wsProtocol}://${url.split("://")[1]}${COLLAB_PATH}`;
|
||||
let url = getAppUrl();
|
||||
if (import.meta.env.DEV) {
|
||||
url = process.env.APP_URL;
|
||||
}
|
||||
|
||||
const wsProtocol = url.startsWith('https') ? 'wss' : 'ws';
|
||||
return `${wsProtocol}://${url.split('://')[1]}${COLLAB_PATH}`;
|
||||
}
|
||||
|
||||
export function getAvatarUrl(avatarUrl: string) {
|
||||
@ -31,17 +35,17 @@ export function getAvatarUrl(avatarUrl: string) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (avatarUrl?.startsWith("http")) {
|
||||
if (avatarUrl?.startsWith('http')) {
|
||||
return avatarUrl;
|
||||
}
|
||||
|
||||
return getBackendUrl() + "/attachments/img/avatar/" + avatarUrl;
|
||||
return getBackendUrl() + '/attachments/img/avatar/' + avatarUrl;
|
||||
}
|
||||
|
||||
export function getSpaceUrl(spaceSlug: string) {
|
||||
return "/s/" + spaceSlug;
|
||||
return '/s/' + spaceSlug;
|
||||
}
|
||||
|
||||
export function getFileUrl(src: string) {
|
||||
return src?.startsWith("/files/") ? getBackendUrl() + src : src;
|
||||
return src?.startsWith('/files/') ? getBackendUrl() + src : src;
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "server",
|
||||
"version": "0.3.0",
|
||||
"version": "0.3.1",
|
||||
"description": "",
|
||||
"author": "",
|
||||
"private": true,
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "docmost",
|
||||
"homepage": "https://docmost.com",
|
||||
"version": "0.3.0",
|
||||
"version": "0.3.1",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"build": "nx run-many -t build",
|
||||
|
||||
Reference in New Issue
Block a user