Skip to content

Move configuration to separate directory#3336

Merged
Martí Climent (marticliment) merged 8 commits intoDevolutions:mainfrom
Layfully:configuration-in-separate-directory
Feb 26, 2025
Merged

Move configuration to separate directory#3336
Martí Climent (marticliment) merged 8 commits intoDevolutions:mainfrom
Layfully:configuration-in-separate-directory

Conversation

@Layfully
Copy link
Copy Markdown
Contributor

@Layfully Adrian Gaborek (Layfully) commented Feb 21, 2025

  • I have read the contributing guidelines, and I agree with the Code of Conduct.
  • Have you checked that there aren't other open pull requests for the same changes?
  • Have you tested that the committed code can be executed without errors?
  • This PR is not composed of garbage changes used to farm GitHub activity to enter potential Crypto AirDrops.
    Any user suspected of farming GitHub activity with crypto purposes will get banned. Submitting broken code wastes the contributors' time, who have to spend their free time reviewing, fixing, and testing code that does not even compile breaks other features, or does not introduce any useful changes. I appreciate your understanding.

To allow symlinking configuration directory I'd like to move all configuration related files to separate directory. Here I'll try to accomplish that without breaking changes i.e for new installations use the new directory directly, for existing ones move settings to the desired directory and use them from there. I try to follow the existing codebase style and hopefully will be able to contribute this feature to the project. I'll keep it draft until I think it's ready for review, will take me some time as I plan to spend 30 minutes to - 1 hour on it when I have free time.

Closes #3285

@marticliment
Copy link
Copy Markdown
Collaborator

The only requirement I would say is that it must be backwards compatible, in the sense that settings must be automatically migrated to the new folder, with the process being transparent to the user

@Layfully Adrian Gaborek (Layfully) marked this pull request as ready for review February 23, 2025 10:33
@Layfully Adrian Gaborek (Layfully) changed the title WIP: Move configuration to separate directory Move configuration to separate directory Feb 23, 2025
@Layfully
Copy link
Copy Markdown
Contributor Author

Adrian Gaborek (Layfully) commented Feb 23, 2025

Hey Martí Climent (@marticliment), I think it's ready for review. I tested it manually, and at startup, all existing configuration files are successfully moved to the Configuration directory. I also wrote tests to cover both fresh installations and scenarios with existing configurations.

Now that configuration files are stored in a separate directory, we could consider adding a setting to allow users to specify a custom path for the configuration directory. This would give them more flexibility in managing their configuration files.

@marticliment
Copy link
Copy Markdown
Collaborator

Now that configuration files are stored in a separate directory, we could consider adding a setting to allow users to specify a custom path for the configuration directory. This would give them more flexibility in managing their configuration files.

This could work in the same way UniGetUI changes settings location when in portable mode

@Layfully
Copy link
Copy Markdown
Contributor Author

Do you mean I should extend something there? My thoughts were just an idea if someone wanted to have it. Currently I'd be happy with what I've implemented if possible

@marticliment
Copy link
Copy Markdown
Collaborator

Currently I'd be happy with what I've implemented if possible

Don't worry then, I will do it eventually. I will test, review and merge soon

@marticliment Martí Climent (marticliment) merged commit 7e6488a into Devolutions:main Feb 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

[IMPROVEMENT] Allow symlink for settings

2 participants