Skip to content

sync #532

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 15 commits into from
Jul 17, 2022
Merged

sync #532

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 29 additions & 26 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,42 +17,45 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Set LD_VERSION
if: ${{ github.event_name == 'push'}}
run: echo "LD_VERSION=${GITHUB_REF#refs/*/v}" >> $GITHUB_ENV
- name: Set LD_VERSION
if: ${{ github.event_name == 'workflow_dispatch'}}
run: echo "LD_VERSION=${{ github.event.inputs.version }}" >> $GITHUB_ENV

- name: Set PUBLISH_TOKEN
run: echo "PUBLISH_TOKEN=${{ secrets.PUBLISH_TOKEN }}" >> $GITHUB_ENV

- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11

- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Build the plugin
run: ./gradlew buildPlugin
run: ./gradlew publishPlugin
env:
LD_VERSION: ${{ env.LD_VERSION }}

- name: Verify plugin
id: verify
uses: ChrisCarini/intellij-platform-plugin-verifier-action@v1.0.5
with:
failure-levels: |
INVALID_PLUGIN
ide-versions: |
ideaIC:2021.1
ideaIC:LATEST-EAP-SNAPSHOT

- name: Print verify contents
run: |
echo "The log file path is: ${{steps.verify.outputs.verification-output-log-filename}}" ;
cat ${{steps.verify.outputs.verification-output-log-filename}}

LD_VERSION: ${{ env.LD_VERSION }}
PUBLISH_TOKEN: ${{ env.PUBLISH_TOKEN }}

# - name: Verify plugin
# id: verify
# uses: ChrisCarini/intellij-platform-plugin-verifier-action@v1.0.5
# with:
# failure-levels: |
# INVALID_PLUGIN
# ide-versions: |
# ideaIC:2020.3
# ideaIC:LATEST-EAP-SNAPSHOT

# - name: Print verify contents
# run: |
# echo "The log file path is: ${{steps.verify.outputs.verification-output-log-filename}}" ;
# cat ${{steps.verify.outputs.verification-output-log-filename}}

- name: Create Release
id: create_release
uses: actions/create-release@v1
Expand All @@ -63,14 +66,14 @@ jobs:
release_name: v${{ env.LD_VERSION }}
draft: true
prerelease: false

- name: Upload Release Asset
id: upload-release-asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./build/distributions/leetcode-editor-${{ env.LD_VERSION }}.zip
asset_name: leetcode-editor-${{ env.LD_VERSION }}.zip
asset_content_type: application/zip
asset_content_type: application/zip
37 changes: 37 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<!-- Keep a Changelog guide -> https://keepachangelog.com -->

# Leetcode Editor Changelog

## 8.2.0

### Added
- 增加了不同的窗口,包括*分页窗口*、*全部题目窗口*、*[CodeTop](https://codetop.cc/?utm_source=leetcode_editor)窗口*,可以在导航栏中通过按钮切换.
- Added different windows, including paging window, all problem window, [CodeTop](https://codetop.cc/?utm_source=leetcode_editor) window, which can be switched by buttons in the navigation bar.

- 增加数据统计信息存储,可配合[action](https://github.com/shuzijun/leetcode-editor/blob/master/action/README_ZH.md)生成勋章
- Increase the storage of data statistics, you can use [action](https://github.com/shuzijun/leetcode-editor/tree/master/action) to generate medals


### Changed
- 修改消息通知方式
- Modify the message notification method

- 更改窗口位置
- Change window position
### Deprecated

### Fixed
- fix bugs

### Removed

## 0.0.0

### Added

### Changed
- Snapshot

### Deprecated

### Removed
169 changes: 116 additions & 53 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,38 +1,50 @@
# leetcode-editor [![Release](https://github.com/shuzijun/leetcode-editor/workflows/Release/badge.svg)](https://github.com/shuzijun/leetcode-editor/releases) [![Snapshot](https://github.com/shuzijun/leetcode-editor/workflows/Snapshot/badge.svg)](https://github.com/shuzijun/leetcode-editor/actions?query=workflow%3ASnapshot)

- [English Document](#Introduction)
- [中文文档](https://github.com/shuzijun/leetcode-editor/blob/master/README_ZH.md)

- Useful Links
- [Login Help](https://github.com/shuzijun/leetcode-editor/blob/master/doc/LoginHelp.md)
- [Custom Code](https://github.com/shuzijun/leetcode-editor/blob/master/doc/CustomCode.md) ([demo](https://github.com/shuzijun/leetcode-question))

# [![Leetcode Editor][plugin-logo]][gh:leetcode-editor] Leetcode Editor

[![Release][badge:release]][gh:releases]
[![Snapshot][badge:snapshot]][gh:snapshot]
[![License][badge:license]][gh:license]
[![Plugin Homepage][badge:plugin-homepage]][plugin-homepage]
[![Version][badge:version]][plugin-versions]
[![Pro Plugin Homepage][badge:plugin-homepage-pro]][plugin-homepage-pro]
[![Version][badge:pro-version]][plugin-versions-pro]
[![Downloads][badge:downloads]][plugin-homepage]
[![English Document][badge:en-doc]][gh:en-doc]
[![中文文档][badge:zh-doc]][gh:zh-doc]
[![捐赠][badge:donate]][shuzijun-donate]
[![内推][badge:referrals]][shuzijun-referrals]

<p align="center"><img src="https://s1.imagehub.cc/images/2022/07/10/leetcode-demo.gif" alt="demo" style="width: auto;height: auto;max-width: 90%; max-height: 90%;"></p>

---

## Introduction
Do Leetcode exercises in IDE, support `leetcode.com` and `leetcode.cn`, to meet the basic needs of doing exercises.
Support theoretically: IntelliJ IDEA PhpStorm WebStorm PyCharm RubyMine AppCode CLion GoLand DataGrip Rider MPS Android Studio.
<a href="http://shuzijun.cn/leetcode-editor/monitor.html" target="_blank">be with you!</a>

Do Leetcode exercises in IDE, support `leetcode.com` and `leetcode.cn`, meet the needs of problem solving and debugging.
Support theoretically: **IntelliJ IDEA**,**PhpStorm**,**WebStorm**,**PyCharm**,**RubyMine**,**AppCode**,**CLion**,**GoLand**,**DataGrip**,**Rider MPS**,**Android Studio**.

- [English Document][gh:en-doc]
- [中文文档][gh:zh-doc]

- Useful Links
- [Login Help][gh:login-help]
- [Custom Code][gh:custom-code] ([demo][gh:leetcode-question])

## How to use
<p align="center">
<img src="https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/leetcode-editor-3.0.gif" alt="demo"/>
</p>
## Getting Started
<p align="center"><img src="https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/doc/leetcode-editor-3.0.gif" alt="start" style="width: auto;height: auto;max-width: 90%; max-height: 90%;"></p>


## Local debugging
<p align="center">
<img src="https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/customConfig-100.gif" alt="demo"/>
</p>
<p align="center"><img src="https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/doc/customConfig-100.gif" alt="loacl" style="width: auto;height: auto;max-width: 90%; max-height: 90%;"></p>


### Installation([help](https://www.jetbrains.com/help/idea/2019.2/managing-plugins.html))
- **Install via plug-in library** [leetcode-editor](https://plugins.jetbrains.com/plugin/12132-leetcode-editor)
- **Install by downloading the file** [releases](https://github.com/shuzijun/leetcode-editor/releases)
- **If you are willing to donate to this project, you can choose the pro version** [leetcode-editor-pro](https://plugins.jetbrains.com/plugin/17166-leetcode-editor-pro)
### Installation([help][managing-plugins])
- **Install via plug-in library** [leetcode-editor][plugin-homepage]
- **Install by downloading the file** [releases][gh:releases]
- **If you are willing to donate to this project, you can choose the pro version** [leetcode-editor-pro][plugin-homepage-pro]

### Configuration (configuration for first installation)

<p align="center">
<img src="https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/config-3.0.png" alt="settings"/>
</p>
<p align="center"><img src="https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/doc/config-3.0.jpg" alt="config" style="width: auto;height: auto;max-width: 90%; max-height: 90%;"></p>


- **Configuration path**: `File` -> `settings`->`tools`->`leetcode plugin`
- **`URL options`**: `leetcode.com`OR`leetcode.cn`
Expand All @@ -41,36 +53,27 @@
- **`Password`**: Login password
- **`Temp File Path`**: Temporary file storage catalogue
- **`proxy(HTTP Proxy)`**: HTTP Proxy,config path:`File` -> `settings`->`Appearance & Behavior`->`System Settings`->`HTTP Proxy`
- **`Custom code template`**: Custom code template ([details](https://github.com/shuzijun/leetcode-editor/blob/master/doc/CustomCode.md)) ([demo](https://github.com/shuzijun/leetcode-question))
- **`Custom code template`**: Custom code template ([details][gh:custom-code]) ([demo][gh:leetcode-question])
- **`LevelColour`**: Customize the difficulty color of the question, it will take effect after restart

### Window (Icon in the lower right corner of the main window![icon](https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/LeetCodeIcon.png))

<p align="center">
<img src="https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/window-3.0.png" alt="window"/>
</p>
### Window

<p align="center"><img src="https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/doc/window-3.0.jpg" alt="window" style="width: auto;height: auto;max-width: 90%; max-height: 90%;"></p>

- **Toolbar**:
- ![login](https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/login.png)**`Sign in`**:The login accounts of the two websites are not interoperable and the corresponding users need to be configured when switching websites.
- ![logout](https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/logout.png)**`Sign out`**:Exit the current account, if you encounter a login error, try to exit first.
- ![refresh](https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/refresh.png)**`Refresh`**:You can also refresh and load questions if you are not logged in, but you cannot submit it.
- ![find](https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/find.png)**`Find`**:Input the content and press Enter to search , press again to search for the next one. It can only search under the question bank node.
- ![collapse](https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/collapseAll.png)**`Collapse`**:Collapse all nodes.
- ![config](https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/config.png)**`Settings`**:Quick jump to the configuration page.
- ![clear](https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/clear.png)**`Clear`**:Clean up the files in the configured cache directories. The cache directories of the two websites are different and only the current configured websites are cleaned up. Carefully clean up cases without submitting.

- **Tree**:
- **`Problems`**:All questions
- **`Difficulty`**:Classification of difficulties
- **`Tags`**:Classification of types
- **`Explore`**:Explore content, only contains titles of the questions, exclusive content that needs to pay ; some questions are loaded in order
- **`Color`**:The color represents the difficulty of the question
- **`Symbol`**:The symbols of “√” and “?” represent the status of the current questions, and explores with the beginning of “$” needs to pay or that cannot be viewed due to other causes.

- ![login][icon:login]**`Sign in`**:The login accounts of the two websites are not interoperable and the corresponding users need to be configured when switching websites.
- ![logout][icon:logout]**`Sign out`**:Exit the current account, if you encounter a login error, try to exit first.
- ![refresh][icon:refresh]**`Refresh`**:You can also refresh and load questions if you are not logged in, but you cannot submit it.
- ![pick][icon:pick]**`pick`**:Open a problem randomly.
- ![find][icon:find]**`Find`**:Open filter panel. You can search, filter and sort.
- ![progress][icon:progress]**`Session`**:Open the Session panel. You can view or switch sessions.
- ![toggle][icon:toggle]**`Toggle List`**:Switch to other list windows, including "All Problem List" , "Paginated Problem List" , "CodeTop Problem List".
- ![config][icon:config]**`Settings`**:Quick jump to the configuration page.
- ![clear][icon:clear]**`Clear`**:Clean up the files in the configured cache directories. The cache directories of the two websites are different and only the current configured websites are cleaned up. Carefully clean up cases without submitting.

### Menu
<p align="center">
<img src="https://raw.githubusercontent.com/shuzijun/leetcode-editor/master/doc/menu-3.0.png" alt="menu"/>
</p>
<p align="center"><img src="https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/doc/menu-3.0.jpg" alt="menu" style="width: auto;height: auto;max-width: 90%; max-height: 90%;"></p>


- **Menu (right-click on the questions)**:
- **`open question`**:Open the question or double click on the question
Expand All @@ -83,5 +86,65 @@
- **`Clear cache`**:Clean up the current question
- **`Timer`**:Timer, when it is turned on, it will prompt the problem solving time in the status bar in the lower right corner

<br>

- **Editor Menu(Right-click on Editor to appear)**:
Function as above
Function as above

<br>

- **Question Editor**:
- **`Content`**:Show content(Rely on Markdown)
- **`Solution`**:show solution
- **`Submissions`**:View the submission record
- **`Note`**:Show note

### Support and Donations
* [donate][shuzijun-donate]


[plugin-logo]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/META-INF/pluginIcon.svg

[badge:plugin-homepage]: https://img.shields.io/badge/Plugin%20Home-Leetcode%20Editor-blue?logo=jetbrains&style=flat-square
[badge:plugin-homepage-pro]: https://img.shields.io/badge/Pro%20Plugin%20Home-Leetcode%20Editor%20Pro-blue?logo=jetbrains&style=flat-square&color=blueviolet
[badge:release]: https://img.shields.io/github/workflow/status/shuzijun/leetcode-editor/Release?style=flat-square&logo=github&&label=Release%20Build
[badge:snapshot]: https://img.shields.io/github/workflow/status/shuzijun/leetcode-editor/Snapshot?style=flat-square&logo=github&&label=Snapshot%20Build
[badge:license]: https://img.shields.io/github/license/shuzijun/leetcode-editor.svg?style=flat-square&&label=License
[badge:downloads]: https://img.shields.io/jetbrains/plugin/d/12132?style=flat-square&label=Plugin%20Downloads&logo=jetbrains
[badge:version]: https://img.shields.io/jetbrains/plugin/v/12132?label=Plugin%20Version&logo=jetbrains&style=flat-square
[badge:pro-version]: https://img.shields.io/jetbrains/plugin/v/17166?label=Pro%20Plugin%20Version&logo=jetbrains&style=flat-square&color=blueviolet
[badge:en-doc]: https://img.shields.io/badge/Docs-English%20Document-blue?logo=docs&style=flat-square
[badge:zh-doc]: https://img.shields.io/badge/Docs-中文文档-blue?logo=docs&style=flat-square
[badge:donate]: https://img.shields.io/badge/Docs-donate-ff69c4?logo=docs&style=flat-square
[badge:referrals]: https://img.shields.io/badge/Docs-referrals-ff69c4?logo=docs&style=flat-square

[icon:leetcode]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/LeetCode_dark.svg
[icon:login]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/login_dark.svg
[icon:logout]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/logout_dark.svg
[icon:refresh]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/refresh_dark.svg
[icon:pick]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/random_dark.svg
[icon:find]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/find_dark.svg
[icon:progress]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/progress_dark.svg
[icon:toggle]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/toggle_dark.svg
[icon:config]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/config_lc_dark.svg
[icon:clear]: https://cdn.jsdelivr.net/gh/shuzijun/leetcode-editor@master/src/main/resources/icons/clear_dark.svg

[gh:leetcode-editor]: https://github.com/shuzijun/leetcode-editor
[gh:releases]: https://github.com/shuzijun/leetcode-editor/releases
[gh:snapshot]: https://github.com/shuzijun/leetcode-editor/actions?query=workflow%3ASnapshot
[gh:license]: https://github.com/shuzijun/leetcode-editor/blob/master/LICENSE
[gh:en-doc]: #Introduction
[gh:zh-doc]: https://github.com/shuzijun/leetcode-editor/blob/master/README_ZH.md
[gh:login-help]: https://github.com/shuzijun/leetcode-editor/blob/master/doc/LoginHelp.md
[gh:custom-code]: https://github.com/shuzijun/leetcode-editor/blob/master/doc/CustomCode.md
[gh:leetcode-question]: https://github.com/shuzijun/leetcode-question
[gh:question]: https://github.com/shuzijun/leetcode-editor/wiki/%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98

[plugin-homepage]: https://plugins.jetbrains.com/plugin/12132-leetcode-editor
[plugin-versions]: https://plugins.jetbrains.com/plugin/12132-leetcode-editor/versions
[plugin-homepage-pro]: https://plugins.jetbrains.com/plugin/17166-leetcode-editor-pro
[plugin-versions-pro]: https://plugins.jetbrains.com/plugin/17166-leetcode-editor-pro/versions
[managing-plugins]: https://www.jetbrains.com/help/idea/managing-plugins.html

[shuzijun-donate]: https://shuzijun.cn/donate.html
[shuzijun-referrals]: https://shuzijun.cn/referrals.html
Loading