Skip to content

Conversation

@ImNotVarun
Copy link
Contributor

Change Wallpaper with the help of Pexel Api

@cibere
Copy link
Contributor

cibere commented Feb 23, 2025

Is there a specific reason that you've chosen to not use the builtin settings system?

@ImNotVarun
Copy link
Contributor Author

I used a text file for storing the API key to keep it simple. If using the built-in settings system is preferred, I can update it

@cibere
Copy link
Contributor

cibere commented Feb 24, 2025

I used a text file for storing the API key to keep it simple. If using the built-in settings system is preferred, I can update it

If you don't have a specific reason to use a different method, could you please switch to the builtin settings system?

Using the builtin settings system would also allow the user to set the API key through your plugin's settings menu, which aligns with how the rest of the plugins work.

@ImNotVarun
Copy link
Contributor Author

ImNotVarun commented Feb 25, 2025 via email

@cibere
Copy link
Contributor

cibere commented Feb 25, 2025

C:\Users\Username\AppData\Roaming\FlowLauncher\Settings\Plugins\Wallpaper Changer i am storing the file in this location is that correct

That seems to be the correct directory, however I still think it would be best to use the builtin settings system.

In case you are unaware how to use the builtin settings system, see the docs for how to define the settings, and for getting them in your code, iirc you can use self.rpc_request["settings"] in your query method to get a dict containing the settings that have been sent with the request.

@ImNotVarun
Copy link
Contributor Author

I've updated the plugin to use the built-in settings system as suggested using flox. The API key is now stored within Flow Launcher's settings system instead of a text file

@cibere
Copy link
Contributor

cibere commented Feb 26, 2025

I appreciate you switching your storage method to use flow's settings system, however I also wanted you to use the SettingsTemplate.yaml file that lets you customize the plugin's settings interface, so that it aligns with how the other plugins work.

You can keep your current code, I'm just asking for the addition of that file

@ImNotVarun
Copy link
Contributor Author

Done , added the SettingsTemplate.yaml file

@ImNotVarun
Copy link
Contributor Author

Hey @cibere, I’ve made all the changes you suggested , Let me know if there’s anything else needed

@cibere
Copy link
Contributor

cibere commented Mar 3, 2025

Hey @cibere, I’ve made all the changes you suggested , Let me know if there’s anything else needed

Thank you for all of the changes that you've made.

@cibere cibere merged commit 72c4407 into Flow-Launcher:plugin_api_v2 Mar 3, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants