• boonhet@lemm.ee
    link
    fedilink
    arrow-up
    24
    arrow-down
    1
    ·
    1 month ago

    Just gitignore that. Same for dot idea and whatever vscode adds, if anything

    • andioop@programming.dev
      link
      fedilink
      English
      arrow-up
      9
      ·
      edit-2
      1 month ago

      git add . > git commit -m "initial" > git push

      Later when I git status or just look at the repo online… “oh crap I let .DS_Store in didn’t I…” and then I remember to set up a .gitignore and make a new commit to take out the .DS_Store and put in the .gitignore.

    • JackbyDev@programming.dev
      link
      fedilink
      English
      arrow-up
      8
      arrow-down
      1
      ·
      1 month ago

      Use this so that the things you need to share do get shared.

      .idea/*
      !.idea/codeStyles
      !.idea/runConfigurations
      
      .vscode/*
      !.vscode/settings.json
      !.vscode/tasks.json
      !.vscode/launch.json
      !.vscode/extensions.json
      !.vscode/*.code-snippets
      

      Note: I haven’t checked the vs code ones in depth, the list might not be perfect.

      • kora@sh.itjust.works
        link
        fedilink
        arrow-up
        14
        arrow-down
        1
        ·
        edit-2
        1 month ago

        I personally strongly advise against committing IDE junk to version control. Assuming your IDE workspace defaults are “sane” for the rest of the contributors is not a good practice.

        • JackbyDev@programming.dev
          link
          fedilink
          English
          arrow-up
          2
          arrow-down
          2
          ·
          1 month ago

          If your whole team uses the same IDE, what’s wrong with commiting things like run configurations and code styles? I agree in general, but a wholesale ban on it is very cargo culty to me. There can be legitimate times to do it.

          • kora@sh.itjust.works
            link
            fedilink
            arrow-up
            7
            arrow-down
            1
            ·
            1 month ago

            I elaborated on it below. Your team will grow and shrink. No guarantee that each developer will bring the same IDE. This is especially true for open source projects.

            If it works your team, no need to be dogmatic about it. Just be careful about what you put there and agree on a set of sane defaults with your team. Your project should build and run tasks without needing a specific IDE.