mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2025-12-26 03:31:24 +08:00
fix: adjust navbar and title bar dimensions, update icon handling feat: implement ChatNavbar component and enhance MainNavbar with search functionality fix: invert transparency setting for WindowService based on OS refactor: clean up MainSidebar and useChat hooks, remove unused state handling and improve topic selection logic refactor: simplify HomeTabs component by removing unused imports and commented code, update AssistantAddItem hover styles fix: set WindowService transparency to false for consistent behavior across platforms feat: add event listener to MainSidebar for topic tab navigation feat: enhance summarization prompt and add topic sidebar visibility toggle feat(Inputbar): add SettingButton component for settings access style(color.scss): update border color to improve UI consistency style: update chat background colors and margins for improved UI consistency refactor(MainSidebar, i18n): update MCP title in sidebar and localization files, remove unused MCP entries feat: remove prompt component refactor(SettingsTab, OpenAISettingsGroup): restructure settings components for improved readability and maintainability, update layout and styling for better user experience feat(ChatNavbar): add maximize and minimize icons for narrow mode toggle style(markdown.scss, CodeBlockView): update border-radius for improved UI consistency and adjust CodeBlock styling style(SettingsTab, OpenAISettingsGroup): adjust padding and minimum height for improved layout, comment out unused components for cleaner code fix(i18n, MessageEditor, Settings): update localization keys for code settings and adjust border radius in MessageEditor, add gap to SettingRow for improved layout feat(ChatNavbar, SVGIcon): add ExpandWidth icon and integrate it into ChatNavbar for narrow mode toggle refactor(ImageBlock, MessageBlockRenderer): enhance image block styling and layout for better responsiveness refactor(MessageAttachments): enhance file icon rendering and filename display with truncation for better UX feat(MainSidebar, AssistantItem): integrate AssistantItem into MainSidebar for topic view, enhance event handling and styling adjustments refactor(MessageAnchorLine): replace DownOutlined icon with CircleChevronDown for improved styling feat(NarrowModeIcon, ChatNavbar): add NarrowModeIcon component and integrate it into ChatNavbar for narrow mode toggle fix(MainSidebar, Inputbar, McpServersList): update event handling, adjust textarea rows, and enhance DragableList styling for improved layout and functionality feat(MainSidebar): enhance submenu animation with framer-motion for improved user experience style(CodeEditor, markdown.scss, SettingsTab): update border-radius to inherit and remove unused SettingDivider for improved consistency style(MainNavbar, Message): adjust padding in MainNavbar and refine alignment logic in MessageItem for improved layout consistency style(Inputbar, SelectModelButton): adjust margins and padding for improved layout consistency and add icon to SelectModelButton wip feat(MainSidebar): restructure sidebar components and add MainNavbar for enhanced navigation and user experience style(MainSidebar, AssistantsTab): adjust margins and padding for improved layout consistency, integrate Scrollbar component for better scrolling experience fix(MessageAnchorLine): prevent rendering of clear message type refactor(SearchMessage, TopicMessages, MessagesService): update locateToMessage function to accept additional parameters for setting active assistant and topic, enhancing navigation logic style(ColorStyles, Messages): update chat background colors for improved visibility and remove redundant background styles in message bubbles revert: hide token show refactor: settings tab refactor(ChatNavbar): remove unused topic handling and simplify shortcut functions fix(useChat): prevent setting active topic if it already exists in active assistant's topics refactor(NavigationHandler, ChatNavbar, HomePage, MainSidebar): streamline navigation logic and remove unused code chore: update react-router and react-router-dom to version 7.6.2, refactor routing logic in App component to use a RouteContainer for better location management refactor(i18n): remove unused topic position settings and assistant display options from English, Japanese, Russian, Chinese, and Greek translations refactor(MainSidebar, PinnedApps): remove unused imports and streamline component structure; update styling for better layout refactor(TopicsTab): remove unused setTopicPosition function and streamline topic time display; update font size and family for TopicTime component refactor(MainSidebar): integrate UserPopup for user settings access; streamline theme toggle logic and enhance styling for active menu items refactor: remove topic position fix(MainSidebar): update settings navigation path from '/settings/general' to '/settings/provider' wip refactor(SettingsTab): replace StyledSelect with Selector component and update styles for better UI consistency chore(release): update fetch depth in GitHub Actions workflow for full history retrieval
153 lines
4.6 KiB
YAML
153 lines
4.6 KiB
YAML
name: Release
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
tag:
|
|
description: 'Release tag (e.g. v1.0.0)'
|
|
required: true
|
|
default: 'v1.0.0'
|
|
push:
|
|
tags:
|
|
- v*.*.*
|
|
|
|
permissions:
|
|
contents: write
|
|
|
|
jobs:
|
|
release:
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
matrix:
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
|
fail-fast: false
|
|
|
|
steps:
|
|
- name: Check out Git repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Get release tag
|
|
id: get-tag
|
|
shell: bash
|
|
run: |
|
|
if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then
|
|
echo "tag=${{ github.event.inputs.tag }}" >> $GITHUB_OUTPUT
|
|
else
|
|
echo "tag=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
|
|
fi
|
|
|
|
- name: Install Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 20
|
|
|
|
- name: macos-latest dependencies fix
|
|
if: matrix.os == 'macos-latest'
|
|
run: |
|
|
brew install python-setuptools
|
|
|
|
- name: Install corepack
|
|
run: corepack enable && corepack prepare yarn@4.6.0 --activate
|
|
|
|
- name: Get yarn cache directory path
|
|
id: yarn-cache-dir-path
|
|
run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT
|
|
|
|
- name: Cache yarn dependencies
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: |
|
|
${{ steps.yarn-cache-dir-path.outputs.dir }}
|
|
node_modules
|
|
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-yarn-
|
|
|
|
- name: Install Dependencies
|
|
run: yarn install
|
|
|
|
- name: Build Linux
|
|
if: matrix.os == 'ubuntu-latest'
|
|
run: |
|
|
yarn build:npm linux
|
|
yarn build:linux
|
|
|
|
env:
|
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
RENDERER_VITE_AIHUBMIX_SECRET: ${{ vars.RENDERER_VITE_AIHUBMIX_SECRET }}
|
|
NODE_OPTIONS: --max-old-space-size=8192
|
|
|
|
- name: Build Mac
|
|
if: matrix.os == 'macos-latest'
|
|
run: |
|
|
sudo -H pip install setuptools
|
|
yarn build:npm mac
|
|
yarn build:mac
|
|
env:
|
|
CSC_LINK: ${{ secrets.CSC_LINK }}
|
|
CSC_KEY_PASSWORD: ${{ secrets.CSC_KEY_PASSWORD }}
|
|
APPLE_ID: ${{ vars.APPLE_ID }}
|
|
APPLE_APP_SPECIFIC_PASSWORD: ${{ vars.APPLE_APP_SPECIFIC_PASSWORD }}
|
|
APPLE_TEAM_ID: ${{ vars.APPLE_TEAM_ID }}
|
|
RENDERER_VITE_AIHUBMIX_SECRET: ${{ vars.RENDERER_VITE_AIHUBMIX_SECRET }}
|
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
NODE_OPTIONS: --max-old-space-size=8192
|
|
|
|
- name: Build Windows
|
|
if: matrix.os == 'windows-latest'
|
|
run: |
|
|
yarn build:npm windows
|
|
yarn build:win
|
|
env:
|
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
RENDERER_VITE_AIHUBMIX_SECRET: ${{ vars.RENDERER_VITE_AIHUBMIX_SECRET }}
|
|
NODE_OPTIONS: --max-old-space-size=8192
|
|
|
|
- name: Release
|
|
uses: ncipollo/release-action@v1
|
|
with:
|
|
draft: true
|
|
allowUpdates: true
|
|
makeLatest: false
|
|
tag: ${{ steps.get-tag.outputs.tag }}
|
|
artifacts: 'dist/*.exe,dist/*.zip,dist/*.dmg,dist/*.AppImage,dist/*.snap,dist/*.deb,dist/*.rpm,dist/*.tar.gz,dist/latest*.yml,dist/rc*.yml,dist/*.blockmap'
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
dispatch-docs-update:
|
|
needs: release
|
|
if: success() && github.repository == 'CherryHQ/cherry-studio' # 确保所有构建成功且在主仓库中运行
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Get release tag
|
|
id: get-tag
|
|
shell: bash
|
|
run: |
|
|
if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then
|
|
echo "tag=${{ github.event.inputs.tag }}" >> $GITHUB_OUTPUT
|
|
else
|
|
echo "tag=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
|
|
fi
|
|
|
|
- name: Check if tag is pre-release
|
|
id: check-tag
|
|
shell: bash
|
|
run: |
|
|
TAG="${{ steps.get-tag.outputs.tag }}"
|
|
if [[ "$TAG" == *"rc"* || "$TAG" == *"pre-release"* ]]; then
|
|
echo "is_pre_release=true" >> $GITHUB_OUTPUT
|
|
else
|
|
echo "is_pre_release=false" >> $GITHUB_OUTPUT
|
|
fi
|
|
|
|
- name: Dispatch update-download-version workflow to cherry-studio-docs
|
|
if: steps.check-tag.outputs.is_pre_release == 'false'
|
|
uses: peter-evans/repository-dispatch@v3
|
|
with:
|
|
token: ${{ secrets.REPO_DISPATCH_TOKEN }}
|
|
repository: CherryHQ/cherry-studio-docs
|
|
event-type: update-download-version
|
|
client-payload: '{"version": "${{ steps.get-tag.outputs.tag }}"}'
|