3 ms·
I had this happen in the past too and found it to be the result of two issues: 1) Using dropbox to house a very large git repo with massive changes and tons of
by bherms 13y ago
I had this happen in the past too and found it to be the result of two issues:
1) Using dropbox to house a very large git repo with massive changes and tons of branches... Every time I switched branches, the hundreds of files would change and obviously kick off a major sync job.
2) There were a few files in a folder than had the owner set to the wrong owner and Dropbox couldn't get permission to access them. This caused it to get stuck in a loop trying to sync those files and Dropbox ended up running my CPU up to over 100% load.
Fix those issues and you shouldn't see it causing any more problems with your battery life.
- easytiger 13y ago> Using dropbox to house a very large git repo with massive changes and tons of branches... Every time I switched branches, the hundreds of files would change and obviously kick off a major sync job. I really have to say honestly: no shit. Sorry if i sound crass but really? When you use an arbitrary piece of software to automatically modify 100s of files the piece of software designed to detect that exact event has do do work and you are complaining? The mind boggles
- simonh 13y agoWhich part of that comment looked to you like a complaint?
- officialjunk 13y agoeasy tiger
- bherms 13y agoWasn't complaining at all... Just pointing out the mistake I made.
- InclinedPlane 13y agoTry this: separate out the git directory from the working directory so that the working directory is not in dropbox but the git directory is. That might solve some of your problems. E.g.: git --git-dir=/home/me/dropbox/git/proj --work-tree=/home/me/proj init
- cnvogel 13y ago(1) you can also use the GIT_DIR environment variable, which might save some typing during development (2) another solution is to just clone the bare repository in Dropbox to a temp-directory, work there, and push the changes back to the Dropbox'ed repo. Saves you the effort to specify GIT_DIR or --git-dir all the time and is the saner approach if you have to switch back and forth between different repos. $ GIT_DIR=~/Dropbox/my_repo git init --bare Initialized empty Git repository in /home/chris/Dropbox/my_repo/ $ git clone ~/Dropbox/my_repo Initialized empty Git repository in /home/chris/my_repo/.git/ warning: You appear to have cloned an empty repository. $ cd my_repo ; touch README $ git add README ; git commit -m "README" ; git push origin master [master (root-commit) ada37ca] README 0 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 README Counting objects: 3, done. Writing objects: 100% (3/3), 213 bytes, done. Total 3 (delta 0), reused 0 (delta 0) Unpacking objects: 100% (3/3), done. To /home/chris/Dropbox/my_repo * [new branch] master -> master
- raverbashing 13y agoDon't use dropbox to solve a solved problem: git backups should go to another git "server" (like bitbucket or github) But yes, the dropbox client devs should go through these bugs and hopefully fix them
- bherms 13y agoYeah, was just oversight on my part at the time... Luckily figured out what was wrong and went another route instead of keeping things in dropbox.
- jlgreco 13y agoIf you are going to use git/Dropbox like that (and I can't say I really recommend it in the first place) then you should keep a bare repo in dropbox and use it as a local 'remote' (check out working repos from it on each computer that you are working on, and push/pull to/from the bare repo in Dropbox).