{"thread":{"id":"55142","subject":"git ability","startedAt":"2021-02-13T13:26:23Z","lastAt":"2021-02-13T17:26:51Z","messageCount":2,"participants":["PANEL Christian","brian m. carlson"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"416837","messageId":"24e39c2c4b7b86aa4a671601a069eaee767a63fb.camel@free.fr","threadId":"55142","inReplyTo":null,"subject":"git ability","fromName":"PANEL Christian","fromEmail":"ch.panel@free.fr","sentAt":"2021-02-13T13:25:03Z","receivedAt":"2021-02-13T13:26:23Z","isPatch":false,"sender":{"key":"ch.panel@free.fr","avatar":null},"body":"hello,\n\ndoes git have the ability to handle a repository on a removable disk?\n\nhere is the experience I had:\n\nI have a project that I manage on a removable disk (therefore with a\n\".git\" directory on it).\n\nuntil now I did \"commits\" and \"push\" on the server from windows10.\n\nI made changes to the source and made a \"commit\" from linux (on the\nsame computer). Git asked me again for my username (email and user\nname): I then thought that these were not stored in the \".git\"\ndirectory\n\nI then saw a new branch called \"linuxcompatibility\" appear.\n\nI would like to understand.\n\nI thought to myself that I would then merge the \"linuxcompatibility\"\nbranch to the \"master\" branch and push it all back to the server.\n\nif that went well with me, on the server the branch\n\"linuxcompatibility\" remained.\n\nhow to get rid of it: nothing seems indicated in the documentation.\n\nThanks for any clarification\n\n"},{"id":"416842","messageId":"YCgLmgrKCV9AIzMI@camp.crustytoothpaste.net","threadId":"55142","inReplyTo":"24e39c2c4b7b86aa4a671601a069eaee767a63fb.camel@free.fr","subject":"Re: git ability","fromName":"brian m. carlson","fromEmail":"sandals@crustytoothpaste.net","sentAt":"2021-02-13T17:25:46Z","receivedAt":"2021-02-13T17:26:51Z","isPatch":false,"sender":{"key":"sandals@crustytoothpaste.net","avatar":"https://avatars.githubusercontent.com/u/497054?v=4"},"body":"On 2021-02-13 at 13:25:03, PANEL Christian wrote:\n> hello,\n> \n> does git have the ability to handle a repository on a removable disk?\n\nYes, this is possible.  You should access it from only one operating\nsystem at a time.\n\nI also strongly recommend that if you're going to do this across\noperating systems, you use UDF[0] and not NTFS, FAT, or exFAT for this\npurpose.  Linux can format drives this way for use across OSes.\n\n> here is the experience I had:\n> \n> I have a project that I manage on a removable disk (therefore with a\n> \".git\" directory on it).\n> \n> until now I did \"commits\" and \"push\" on the server from windows10.\n> \n> I made changes to the source and made a \"commit\" from linux (on the\n> same computer). Git asked me again for my username (email and user\n> name): I then thought that these were not stored in the \".git\"\n> directory\n\nThese settings, user.name and user.email, _can_ be stored in\n.git/config, but _usually_ are stored in the user's home directory,\nwhich will differ between operating systems.  You can use the \"git\nconfig\" tool to set them appropriately if you'd like.  I personally sync\nmy dotfiles across machines, which includes .gitconfig, which is an\napproach many others use as well.\n\n> I then saw a new branch called \"linuxcompatibility\" appear.\n> \n> I would like to understand.\n\nGit doesn't create branches unless requested.  It's possible that some\nother tool on your system did.  For example, if you're using a file\nsyncing service (e.g., Dropbox or OneDrive) to sync data, that's\ndefinitely not recommended and can cause problems like this.  If you're\nusing WSL instead of a true Linux system, that data could also have been\ncreated by Windows.\n\nIt's also possible that this branch already existed on the server and it\nmay have shown up as a remote tracking branch with \"git branch -a\", in\nwhich case attempting to check it out may have created a local copy.\n\nWithout more details or output from a program, it's hard to say what's\ngoing on here.\n\n> I thought to myself that I would then merge the \"linuxcompatibility\"\n> branch to the \"master\" branch and push it all back to the server.\n> \n> if that went well with me, on the server the branch\n> \"linuxcompatibility\" remained.\n\nIf you want to delete a branch on the remote server, you can do this:\n\n  git push -d origin linuxcompatibility\n\nIf you want to delete a branch locally, you can do this:\n\n  git branch -d linuxcompatibility\n\n[0] https://en.wikipedia.org/wiki/Universal_Disk_Format; v2.01 is\nrecommended.\n-- \nbrian m. carlson (he/him or they/them)\nHouston, Texas, US\n"}]}