What causes an entry in my git config file for every LFS file I add?How to remove local (untracked) files from the current Git working tree?How can I add an empty directory to a Git repository?Reset or revert a specific file to a specific revision using Git?View the change history of a file using Git versioningWhat is the difference between 'git pull' and 'git fetch'?How do I undo 'git add' before commit?Difference between “git add -A” and “git add .”How do I force “git pull” to overwrite local files?How to make Git “forget” about a file that was tracked but is now in .gitignore?How do I properly force a Git push?

The alcoholic village festival

Why is exile often an intermediate step?

Why do some PCBs have exposed plated perimeters?

What was the point of separating stdout and stderr?

Two palindromes are not enough

How useful would a hydroelectric power plant be in the post-apocalypse world?

Why would Dementors torture a Death Eater if they are loyal to Voldemort?

Is this house-rule removing the increased effect of cantrips at higher character levels balanced?

Why wasn't ASCII designed with a contiguous alphanumeric character order?

Is it OK to say "The situation is pregnant with a crisis"?

Is leaving out prefixes like "rauf", "rüber", "rein" when describing movement considered a big mistake in spoken German?

Calculus, water poured into a cone: Why is the derivative non-linear?

What is the lowest possible AC?

Why am I getting an electric shock from the water in my hot tub?

Automorphisms and epimorphisms of finite groups

Does friction always oppose motion?

Is it possible to alias a column based on the result of a select+where?

How to draw a diagram like this with tikz?

Did the Russian Empire have a claim to Sweden? Was there ever a time where they could have pursued it?

Can US Supreme Court justices / judges be "rotated" out against their will?

What prevents a US state from colonizing a smaller state?

German idiomatic equivalents of 能骗就骗 (if you can cheat, then cheat)

Why is my 401k manager recommending me to save more?

Reusable spacecraft: why still have fairings detach, instead of open/close?



What causes an entry in my git config file for every LFS file I add?


How to remove local (untracked) files from the current Git working tree?How can I add an empty directory to a Git repository?Reset or revert a specific file to a specific revision using Git?View the change history of a file using Git versioningWhat is the difference between 'git pull' and 'git fetch'?How do I undo 'git add' before commit?Difference between “git add -A” and “git add .”How do I force “git pull” to overwrite local files?How to make Git “forget” about a file that was tracked but is now in .gitignore?How do I properly force a Git push?













6















I recently added many (new) files to my git repository and am tracking them with Git LFS. My remote is BitBucket and it all works nicely as intended.



Except, for every file I add to LFS, an entry is added to my .git/config that looks like this:



[lfs "https://bitbucket.org/%7B%7D/%7B********-****-****-****-****6bcd1adc%7D/info/lfs/object/verify?upload_id=********-d87a-47f9-a857-ae04********"]
access = basic


(All the *'s are hexadecimal characters I removed for security reasons)



Since one entry is added for every file I track and push with LFS and I have hundreds of files in LFS, my git config file is now huge.



I think this issue started after switching my origin remote (from one BitBucket repo to another).



What's going on and more importantly, how can I fix this?



Can I safely delete these entries from .git/config?




For reference, this is how the BitBucket remote is configured in the same config file:



[remote "origin"]
url = https://user@bitbucket.org/user/repository.git
fetch = +refs/heads/*:refs/remotes/origin/*
[lfs "https://user@bitbucket.org/user/repository.git/info/lfs"]
locksverify = false
access = basic
[lfs "https://bitbucket.org/user/repository.git/info/lfs"]
access = basic


And this is what the LFS part of .gitattributes in the root of the repo looks like:



...
database/seeds/sql/content/*/allcontent.sql filter=lfs diff=lfs merge=lfs -text
public/img/*/path1/*.normal@2x.jpg filter=lfs diff=lfs merge=lfs -text
public/img/*/path2/*.normal@2x.jpg filter=lfs diff=lfs merge=lfs -text


Update; I ran git lfs uninstall and then git lfs install --local in the repo to see if it fixes anything, it doesn't (that's to say, more lines were still being added to .git/config for new files I added to LFS). My .git/config file is now over 110KB large :S



Update 2: I was in touch with BitBucket, the only response I got so far is that this is expected behavior and something about pruning local LFS files, so I think they don't understand the issue I submitted. I suspect you can fix this the brutal way by removing the remote repository at BitBucket and all files tracked with LFS from your working directory, uninstalling Git LFS, removing the LFS directory from your Git repo, removing all .gitattributes lines that reference LFS, doing a new commit locally, using BFG or something like it to remove the references to all LFS-tracked files from all historic commits (depending on how you do it, this might make the tracked files go missing from all historical commits - I followed this article), then re-installing Git LFS and re-tracking and adding the files before pushing to a repo newly created at BitBucket. I did just this but without the final step of re-installing Git LFS - for now I'll just stick to tracking those files the regular way. If using LFS is absolutely necessary I suspect these steps will fix it (at the price of possibly losing historical commit integrity) but I'm not sure either. If I get another response from BitBucket I'll be sure to update this issue.



Update 3: BitBucket now understands the issue and is investigating.










share|improve this question
























  • it looks like instead of just adding a tracked file for a single lfs repository, it's adding a complete entry for the url of the lfs repository, it might be something in the way lfs is configured, it does appear that the lfs urls in the .gitconfig do not match the ones configured in the repository.

    – JamesD
    Mar 14 at 23:46











  • Thanks for your reply JamesD! How would I go about configuring lfs or seeing what the current config is?

    – Wilbo Baggins
    Mar 14 at 23:49











  • @JamesD you have any clue mate?

    – Wilbo Baggins
    Mar 23 at 15:19















6















I recently added many (new) files to my git repository and am tracking them with Git LFS. My remote is BitBucket and it all works nicely as intended.



Except, for every file I add to LFS, an entry is added to my .git/config that looks like this:



[lfs "https://bitbucket.org/%7B%7D/%7B********-****-****-****-****6bcd1adc%7D/info/lfs/object/verify?upload_id=********-d87a-47f9-a857-ae04********"]
access = basic


(All the *'s are hexadecimal characters I removed for security reasons)



Since one entry is added for every file I track and push with LFS and I have hundreds of files in LFS, my git config file is now huge.



I think this issue started after switching my origin remote (from one BitBucket repo to another).



What's going on and more importantly, how can I fix this?



Can I safely delete these entries from .git/config?




For reference, this is how the BitBucket remote is configured in the same config file:



[remote "origin"]
url = https://user@bitbucket.org/user/repository.git
fetch = +refs/heads/*:refs/remotes/origin/*
[lfs "https://user@bitbucket.org/user/repository.git/info/lfs"]
locksverify = false
access = basic
[lfs "https://bitbucket.org/user/repository.git/info/lfs"]
access = basic


And this is what the LFS part of .gitattributes in the root of the repo looks like:



...
database/seeds/sql/content/*/allcontent.sql filter=lfs diff=lfs merge=lfs -text
public/img/*/path1/*.normal@2x.jpg filter=lfs diff=lfs merge=lfs -text
public/img/*/path2/*.normal@2x.jpg filter=lfs diff=lfs merge=lfs -text


Update; I ran git lfs uninstall and then git lfs install --local in the repo to see if it fixes anything, it doesn't (that's to say, more lines were still being added to .git/config for new files I added to LFS). My .git/config file is now over 110KB large :S



Update 2: I was in touch with BitBucket, the only response I got so far is that this is expected behavior and something about pruning local LFS files, so I think they don't understand the issue I submitted. I suspect you can fix this the brutal way by removing the remote repository at BitBucket and all files tracked with LFS from your working directory, uninstalling Git LFS, removing the LFS directory from your Git repo, removing all .gitattributes lines that reference LFS, doing a new commit locally, using BFG or something like it to remove the references to all LFS-tracked files from all historic commits (depending on how you do it, this might make the tracked files go missing from all historical commits - I followed this article), then re-installing Git LFS and re-tracking and adding the files before pushing to a repo newly created at BitBucket. I did just this but without the final step of re-installing Git LFS - for now I'll just stick to tracking those files the regular way. If using LFS is absolutely necessary I suspect these steps will fix it (at the price of possibly losing historical commit integrity) but I'm not sure either. If I get another response from BitBucket I'll be sure to update this issue.



Update 3: BitBucket now understands the issue and is investigating.










share|improve this question
























  • it looks like instead of just adding a tracked file for a single lfs repository, it's adding a complete entry for the url of the lfs repository, it might be something in the way lfs is configured, it does appear that the lfs urls in the .gitconfig do not match the ones configured in the repository.

    – JamesD
    Mar 14 at 23:46











  • Thanks for your reply JamesD! How would I go about configuring lfs or seeing what the current config is?

    – Wilbo Baggins
    Mar 14 at 23:49











  • @JamesD you have any clue mate?

    – Wilbo Baggins
    Mar 23 at 15:19













6












6








6


2






I recently added many (new) files to my git repository and am tracking them with Git LFS. My remote is BitBucket and it all works nicely as intended.



Except, for every file I add to LFS, an entry is added to my .git/config that looks like this:



[lfs "https://bitbucket.org/%7B%7D/%7B********-****-****-****-****6bcd1adc%7D/info/lfs/object/verify?upload_id=********-d87a-47f9-a857-ae04********"]
access = basic


(All the *'s are hexadecimal characters I removed for security reasons)



Since one entry is added for every file I track and push with LFS and I have hundreds of files in LFS, my git config file is now huge.



I think this issue started after switching my origin remote (from one BitBucket repo to another).



What's going on and more importantly, how can I fix this?



Can I safely delete these entries from .git/config?




For reference, this is how the BitBucket remote is configured in the same config file:



[remote "origin"]
url = https://user@bitbucket.org/user/repository.git
fetch = +refs/heads/*:refs/remotes/origin/*
[lfs "https://user@bitbucket.org/user/repository.git/info/lfs"]
locksverify = false
access = basic
[lfs "https://bitbucket.org/user/repository.git/info/lfs"]
access = basic


And this is what the LFS part of .gitattributes in the root of the repo looks like:



...
database/seeds/sql/content/*/allcontent.sql filter=lfs diff=lfs merge=lfs -text
public/img/*/path1/*.normal@2x.jpg filter=lfs diff=lfs merge=lfs -text
public/img/*/path2/*.normal@2x.jpg filter=lfs diff=lfs merge=lfs -text


Update; I ran git lfs uninstall and then git lfs install --local in the repo to see if it fixes anything, it doesn't (that's to say, more lines were still being added to .git/config for new files I added to LFS). My .git/config file is now over 110KB large :S



Update 2: I was in touch with BitBucket, the only response I got so far is that this is expected behavior and something about pruning local LFS files, so I think they don't understand the issue I submitted. I suspect you can fix this the brutal way by removing the remote repository at BitBucket and all files tracked with LFS from your working directory, uninstalling Git LFS, removing the LFS directory from your Git repo, removing all .gitattributes lines that reference LFS, doing a new commit locally, using BFG or something like it to remove the references to all LFS-tracked files from all historic commits (depending on how you do it, this might make the tracked files go missing from all historical commits - I followed this article), then re-installing Git LFS and re-tracking and adding the files before pushing to a repo newly created at BitBucket. I did just this but without the final step of re-installing Git LFS - for now I'll just stick to tracking those files the regular way. If using LFS is absolutely necessary I suspect these steps will fix it (at the price of possibly losing historical commit integrity) but I'm not sure either. If I get another response from BitBucket I'll be sure to update this issue.



Update 3: BitBucket now understands the issue and is investigating.










share|improve this question
















I recently added many (new) files to my git repository and am tracking them with Git LFS. My remote is BitBucket and it all works nicely as intended.



Except, for every file I add to LFS, an entry is added to my .git/config that looks like this:



[lfs "https://bitbucket.org/%7B%7D/%7B********-****-****-****-****6bcd1adc%7D/info/lfs/object/verify?upload_id=********-d87a-47f9-a857-ae04********"]
access = basic


(All the *'s are hexadecimal characters I removed for security reasons)



Since one entry is added for every file I track and push with LFS and I have hundreds of files in LFS, my git config file is now huge.



I think this issue started after switching my origin remote (from one BitBucket repo to another).



What's going on and more importantly, how can I fix this?



Can I safely delete these entries from .git/config?




For reference, this is how the BitBucket remote is configured in the same config file:



[remote "origin"]
url = https://user@bitbucket.org/user/repository.git
fetch = +refs/heads/*:refs/remotes/origin/*
[lfs "https://user@bitbucket.org/user/repository.git/info/lfs"]
locksverify = false
access = basic
[lfs "https://bitbucket.org/user/repository.git/info/lfs"]
access = basic


And this is what the LFS part of .gitattributes in the root of the repo looks like:



...
database/seeds/sql/content/*/allcontent.sql filter=lfs diff=lfs merge=lfs -text
public/img/*/path1/*.normal@2x.jpg filter=lfs diff=lfs merge=lfs -text
public/img/*/path2/*.normal@2x.jpg filter=lfs diff=lfs merge=lfs -text


Update; I ran git lfs uninstall and then git lfs install --local in the repo to see if it fixes anything, it doesn't (that's to say, more lines were still being added to .git/config for new files I added to LFS). My .git/config file is now over 110KB large :S



Update 2: I was in touch with BitBucket, the only response I got so far is that this is expected behavior and something about pruning local LFS files, so I think they don't understand the issue I submitted. I suspect you can fix this the brutal way by removing the remote repository at BitBucket and all files tracked with LFS from your working directory, uninstalling Git LFS, removing the LFS directory from your Git repo, removing all .gitattributes lines that reference LFS, doing a new commit locally, using BFG or something like it to remove the references to all LFS-tracked files from all historic commits (depending on how you do it, this might make the tracked files go missing from all historical commits - I followed this article), then re-installing Git LFS and re-tracking and adding the files before pushing to a repo newly created at BitBucket. I did just this but without the final step of re-installing Git LFS - for now I'll just stick to tracking those files the regular way. If using LFS is absolutely necessary I suspect these steps will fix it (at the price of possibly losing historical commit integrity) but I'm not sure either. If I get another response from BitBucket I'll be sure to update this issue.



Update 3: BitBucket now understands the issue and is investigating.







git bitbucket git-lfs






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 25 at 15:39







Wilbo Baggins

















asked Mar 14 at 23:33









Wilbo BagginsWilbo Baggins

2,0312 gold badges20 silver badges34 bronze badges




2,0312 gold badges20 silver badges34 bronze badges












  • it looks like instead of just adding a tracked file for a single lfs repository, it's adding a complete entry for the url of the lfs repository, it might be something in the way lfs is configured, it does appear that the lfs urls in the .gitconfig do not match the ones configured in the repository.

    – JamesD
    Mar 14 at 23:46











  • Thanks for your reply JamesD! How would I go about configuring lfs or seeing what the current config is?

    – Wilbo Baggins
    Mar 14 at 23:49











  • @JamesD you have any clue mate?

    – Wilbo Baggins
    Mar 23 at 15:19

















  • it looks like instead of just adding a tracked file for a single lfs repository, it's adding a complete entry for the url of the lfs repository, it might be something in the way lfs is configured, it does appear that the lfs urls in the .gitconfig do not match the ones configured in the repository.

    – JamesD
    Mar 14 at 23:46











  • Thanks for your reply JamesD! How would I go about configuring lfs or seeing what the current config is?

    – Wilbo Baggins
    Mar 14 at 23:49











  • @JamesD you have any clue mate?

    – Wilbo Baggins
    Mar 23 at 15:19
















it looks like instead of just adding a tracked file for a single lfs repository, it's adding a complete entry for the url of the lfs repository, it might be something in the way lfs is configured, it does appear that the lfs urls in the .gitconfig do not match the ones configured in the repository.

– JamesD
Mar 14 at 23:46





it looks like instead of just adding a tracked file for a single lfs repository, it's adding a complete entry for the url of the lfs repository, it might be something in the way lfs is configured, it does appear that the lfs urls in the .gitconfig do not match the ones configured in the repository.

– JamesD
Mar 14 at 23:46













Thanks for your reply JamesD! How would I go about configuring lfs or seeing what the current config is?

– Wilbo Baggins
Mar 14 at 23:49





Thanks for your reply JamesD! How would I go about configuring lfs or seeing what the current config is?

– Wilbo Baggins
Mar 14 at 23:49













@JamesD you have any clue mate?

– Wilbo Baggins
Mar 23 at 15:19





@JamesD you have any clue mate?

– Wilbo Baggins
Mar 23 at 15:19










0






active

oldest

votes










Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55173538%2fwhat-causes-an-entry-in-my-git-config-file-for-every-lfs-file-i-add%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes




Is this question similar to what you get asked at work? Learn more about asking and sharing private information with your coworkers using Stack Overflow for Teams.







Is this question similar to what you get asked at work? Learn more about asking and sharing private information with your coworkers using Stack Overflow for Teams.



















draft saved

draft discarded
















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55173538%2fwhat-causes-an-entry-in-my-git-config-file-for-every-lfs-file-i-add%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

Swift 4 - func physicsWorld not invoked on collision? The Next CEO of Stack OverflowHow to call Objective-C code from Swift#ifdef replacement in the Swift language@selector() in Swift?#pragma mark in Swift?Swift for loop: for index, element in array?dispatch_after - GCD in Swift?Swift Beta performance: sorting arraysSplit a String into an array in Swift?The use of Swift 3 @objc inference in Swift 4 mode is deprecated?How to optimize UITableViewCell, because my UITableView lags

Access current req object everywhere in Node.js ExpressWhy are global variables considered bad practice? (node.js)Using req & res across functionsHow do I get the path to the current script with Node.js?What is Node.js' Connect, Express and “middleware”?Node.js w/ express error handling in callbackHow to access the GET parameters after “?” in Express?Modify Node.js req object parametersAccess “app” variable inside of ExpressJS/ConnectJS middleware?Node.js Express app - request objectAngular Http Module considered middleware?Session variables in ExpressJSAdd properties to the req object in expressjs with Typescript