Skip to content

Considering to merge 'leetcode.workspaceFolder' and 'leetcode.outputFolder' into one single setting. #372

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

Closed
jdneo opened this issue Jul 25, 2019 · 8 comments
Labels
enhancement New feature or request

Comments

@jdneo
Copy link
Member

jdneo commented Jul 25, 2019

🚀 Feature Proposal

Currently the leetcode.workspaceFolder is used to specify the folder path and leetcode.outputFolder is used to specify the relative path. But it's confusing. Merge them into one single setting might be a good choice.

@jdneo jdneo added the enhancement New feature or request label Jul 25, 2019
@magic-akari
Copy link
Contributor

Maybe it is better to use current opened folder as leetcode.workspaceFolder.

手工指定 workspaceFolder 感觉有点奇怪,直接使用当前打开的文件夹作为工作目录不是更自然么?

至于没有打开文件夹的情况,这种模式和这个插件的工作模式是相悖的,因为插件无论如何都要找一个地方写入文件,所以比如是要打开一个文件夹才对。要么报错,要么引导用户打开文件夹,这种处理方式。

另外,我觉得 outputFolder 应该和 fileName 合并,直接改成相对路径 filePath,您觉得如何?

@jdneo
Copy link
Member Author

jdneo commented Aug 2, 2019

手工指定 workspaceFolder 感觉有点奇怪,直接使用当前打开的文件夹作为工作目录不是更自然么?

I don't think we should use the current active folder as workspaceFolder. Imagine you have opened other project in your VS Code. Generate LeetCode files in the current folder will ruin your source control.

至于没有打开文件夹的情况,这种模式和这个插件的工作模式是相悖的,因为插件无论如何都要找一个地方写入文件,所以比如是要打开一个文件夹才对。要么报错,要么引导用户打开文件夹,这种处理方式。

Yes, the current behavior will prompt the user to open the specified folder, just as you have said.

另外,我觉得 outputFolder 应该和 fileName 合并,直接改成相对路径 filePath,您觉得如何?

Hmm, currently the extension does not support customize the file name yet.

@magic-akari
Copy link
Contributor

我打算修改,以便支持自定义文件名。请问是否接受 PR?

另外,是否保留 outputFolder 这个设置,我还没什么想法。

@jdneo
Copy link
Member Author

jdneo commented Aug 2, 2019

@magic-akari All the contribution is welcome! We actually have an issue for this: #166. I suggest we can discuss in that issue to address a design before the PR is sent out.

@jwbecalm
Copy link

jwbecalm commented Sep 3, 2019

how to config the "leetcode.workspaceFolder" ? I want to change after my first choose, but I cannot find it in workspace settings

@jdneo
Copy link
Member Author

jdneo commented Sep 3, 2019

@jwbecalm It's in the user settings.

@jdneo
Copy link
Member Author

jdneo commented Sep 14, 2019

Close since the leetcode.outputFolder has been deprecated.

@jdneo jdneo closed this as completed Sep 14, 2019
@Streamlet
Copy link

但是现在如果我想以当前工作目录为参考的相对路径,要怎么设置呢?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants