Skip to content
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

Allow import all database subfolders by selecting a folder #3797

Merged
merged 17 commits into from
Nov 19, 2024

Conversation

reitowo
Copy link
Contributor

@reitowo reitowo commented Nov 7, 2024

Add a palette command that allow user to select a folder and import all database subfolders.

This helps a lot when dealing with micro services that has dozens of databases and save user's time from repeatly choosing folders one by one.

image

@reitowo reitowo requested review from a team as code owners November 7, 2024 13:57
@reitowo reitowo changed the title feat: allow import all database subfolders by selecting a folder Allow import all database subfolders by selecting a folder Nov 7, 2024
@reitowo reitowo force-pushed the main-multiple-folder branch 2 times, most recently from 7f0e8bc to 1196902 Compare November 7, 2024 23:51
Copy link
Contributor

@aeisenberg aeisenberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution. I've given it an initial review, but I haven't tried this out locally yet.

extensions/ql-vscode/CHANGELOG.md Outdated Show resolved Hide resolved
extensions/ql-vscode/package.json Outdated Show resolved Hide resolved
extensions/ql-vscode/src/databases/local-databases-ui.ts Outdated Show resolved Hide resolved
@reitowo
Copy link
Contributor Author

reitowo commented Nov 13, 2024

I seperated this logic out of original import folder function for better structure. Also optimized log output and unified names of this command for better understanding.

@reitowo
Copy link
Contributor Author

reitowo commented Nov 13, 2024

Done here.

@aeisenberg aeisenberg self-assigned this Nov 18, 2024
Copy link
Contributor

@aeisenberg aeisenberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried this out and it seems to work fine. I have some more suggestions around the error messages.

Once this is done, I think it is good to merge.

extensions/ql-vscode/src/databases/local-databases-ui.ts Outdated Show resolved Hide resolved
extensions/ql-vscode/src/databases/local-databases-ui.ts Outdated Show resolved Hide resolved
extensions/ql-vscode/src/databases/local-databases-ui.ts Outdated Show resolved Hide resolved
extensions/ql-vscode/src/databases/local-databases-ui.ts Outdated Show resolved Hide resolved
extensions/ql-vscode/package.json Outdated Show resolved Hide resolved
extensions/ql-vscode/src/databases/local-databases-ui.ts Outdated Show resolved Hide resolved
extensions/ql-vscode/src/databases/local-databases-ui.ts Outdated Show resolved Hide resolved
Comment on lines +367 to +370
return withProgress(async (progress) => {
await this.chooseDatabasesParentFolder(progress);
});
}
Copy link
Contributor Author

@reitowo reitowo Nov 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aeisenberg Updated according to your suggestions with minor refine.

I also removed the title of this progress bar, because otherwise the whole message will be too long and doesn't display the actual step message of each database.

Currently will be:
image

Before:
image

@reitowo reitowo force-pushed the main-multiple-folder branch from 1fac1b1 to 8b3add8 Compare November 19, 2024 16:06
@aeisenberg
Copy link
Contributor

I added one more update to the changelog and then it is ready to merge.

@reitowo
Copy link
Contributor Author

reitowo commented Nov 19, 2024

Thanks!

@aeisenberg aeisenberg merged commit 025737a into github:main Nov 19, 2024
16 checks passed
@aeisenberg
Copy link
Contributor

Thanks for your contribution!

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

Successfully merging this pull request may close these issues.

2 participants