Save Files as Unminified JSON

Discussion in 'JS Plugin Requests' started by professorbeej, Apr 5, 2019.

  1. professorbeej

    professorbeej Villager Member

    Messages:
    29
    Likes Received:
    10
    Location:
    Alabama
    First Language:
    English
    Primarily Uses:
    RMMV
    Hey, folks. My partner and I are collaborating remotely on our game, and we are using GitHub to do it. It works great for the most part, except when I am trying to merge branches or pull requests.

    What happens is that if either of us has edited MapInfos.json or Actors.json or System.json or whatever (which of course we have), git can't parse the conflicts that come up. Even if they are not overlapping.

    Because RMMV saves all the files during development as minified JSON, git just sees a single line that has conflicts. What I've been able to do so far is use a JSON beautifier/unminifier (link here in case anyone else needs it) and then manually go through the files in VS Code and decide whether I want to keep the current change or the incoming change.

    It's not that bad, but it's a real pain. It would be so much easier if git could parse the actual lines of code like it's designed to do.

    So all that to say: has anyone figured out a way to get RMMV to save the data files as unminified JSON by default?
     
    #1
  2. Jonforum

    Jonforum Veteran Veteran

    Messages:
    1,577
    Likes Received:
    1,353
    Location:
    Canada / Québec
    First Language:
    French
    Primarily Uses:
    RMMV
    you c'ant
    use .gitignor on those file.
     
    #2
  3. professorbeej

    professorbeej Villager Member

    Messages:
    29
    Likes Received:
    10
    Location:
    Alabama
    First Language:
    English
    Primarily Uses:
    RMMV
    That would basically be .gitignoring everything in the repo except for the image assets, wouldn't it? Then my partner wouldn't be able to get any of the changes I made, and I wouldn't get his, if I understand right, right?
     
    #3
  4. Jonforum

    Jonforum Veteran Veteran

    Messages:
    1,577
    Likes Received:
    1,353
    Location:
    Canada / Québec
    First Language:
    French
    Primarily Uses:
    RMMV
    hum ho ok i understand more , forget me , this solution it not for your context !
    You can maybe find a wayt to edit git to ignor error , but allow github to update files for your team.
    With a .gitignor file , you will not allow to `fech origin` your ignored json files to github.

    The only solution i can see, wait if people have more...
    Iyt to create a .bat file, and when your ready to share , execute the .bat that will unminified the rmmv json.
    You will need study how create a .bat.

    Or ask the rmmv team sofware dev to allow this.

    And for gitignor , you can tell what folder or file you want ignor.
    upload_2019-4-4_16-34-38.png
     
    #4
  5. Aloe Guvner

    Aloe Guvner Walrus Veteran

    Messages:
    1,561
    Likes Received:
    978
    Location:
    USA
    First Language:
    English
    Primarily Uses:
    RMMV
    #5

Share This Page