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

Updating deletes previously set homes #1

Closed
blackfox1482 opened this issue Jun 30, 2019 · 5 comments
Closed

Updating deletes previously set homes #1

blackfox1482 opened this issue Jun 30, 2019 · 5 comments
Assignees

Comments

@blackfox1482
Copy link

blackfox1482 commented Jun 30, 2019

Hello, I love using this plugin on my server, however when I tried updating to the newest version of the plugin it deletes all previously set homes. I am not sure what the problem is but I was hoping you would be able to help. I am currently still using the 1.13 version of the plugin. Thanks!

@Xquiset Xquiset pinned this issue Jul 2, 2019
@Xquiset Xquiset self-assigned this Jul 2, 2019
@Xquiset
Copy link
Owner

Xquiset commented Jul 2, 2019

Hi there,

The issue is because of bugs in the previous code which resulted in a malformed configuration file. Due to this I had to rework the way the configuration file got created and written out to whenever someone saved a new home. Unfortunately because of this I was unable to safely reuse the old configurations for this new version of the plugin. Therefore the only way I can see to fix this problem is as follows:

  1. Navigate to your bukkit servers plugin directory, and from there into the folder "SetHomes". In your case, and the same goes for anybody else who updated, there should be three files within this folder, "sethomes.yml", "sethomes_desc.yml", and "config.yml". The two files "sethomes.yml" and "sethomes_desc.yml" are leftover from the previous version of the plugin. These will contain all the information regarding the old homes before the update. The file "config.yml" contains all the new homes that have been created after the update.

    • NOTE: BACKUP THIS FOLDER IN CASE ANY MISTAKES ARE MADE DURING THE PROCESS!!!
  2. Open up "sethomes.yml", as we will need to clean up any errors that the previous version of the plugin may have created due to its bugs. From here we need to delete any items that fit under the following criteria:

    • Any combination of characters similar to "&i003", or "*i003"
    • Any line containing "==: org.bukkit.location"
    • Any line containing a home name followed by any combination of charaters similar to "&i003", or "*i003"
    • Anything outlined in red is an example of what to delete.
      screenshot_step_2
  3. You will need to get the descriptions from within "sethomes_desc.yml" and move them to the correct location in "sethomes.yml". Make sure that you match the player UUID which looks something like (9b40d35c-908a-43ee-9e07-8e97d16e3b99), and is used to identify a specific player, as well as the home name when pasting the description into its proper indented location.

    • Any block outlined in blue must match prior to pasting the left side green block into the right sides green block.
      screenshot_step_3

    • If done correctly your "sethomes.yml" should now look similar to this:
      screenshot_step_3_outcome

  4. Following the same process as step three, where you have to match the player UUID. Copy over any home that does not already have a name under the corresponding UUID into "config.yml"

    • Anything outlined in blue must match prior to pasting in the item outlined in green.
      screenshot_step_4
    • If all of the steps were followed properly then you should end up with an updated version of "config.yml" that looks something like this: updated_config_yml. Then all of the old homes that were not malformed by the bug in the previous version of this plugin should be restored after you save "config.yml" and restart the server.

Best of luck and I am so sorry for the inconvenience,
Xquiset

@Xquiset Xquiset closed this as completed Jul 2, 2019
@blackfox1482
Copy link
Author

I am sad that this is how it has to be fixed. I have to delete 4447 things just for *id---- and I have to do this by hand no shortcuts.

@Xquiset
Copy link
Owner

Xquiset commented Jul 8, 2019

I very sorry that this is the only option available, and to hear of the significant work it has burdened you with. In terms of the shortcuts my best suggestion would be to find a nice text editor that lets you use "regular expressions" in its find and replace functionality. I'm not here to give a tutorial on how to use "regular expressions", but I think if you can figure that out then it will significantly cut down the amount of work that you would have to do by hand. For example the text editor I am using in the screenshots above is called "Sublime 3" and it allows you to use "regular expressions" in its find and replace.

Again, so sorry for the inconvenience,
Xquiset

@blackfox1482
Copy link
Author

No worries, I understand that you didn't for see this happening. It is all good now I spent the last few days just working on it and it is all done now yay! :)

@Xquiset
Copy link
Owner

Xquiset commented Jul 12, 2019

Thank you for understanding. I am very happy to hear that you got everything sorted out!

Happy Crafting :)
Xquiset

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

No branches or pull requests

2 participants