I accidentally checked out a bunch of files in an undesired CVS directory, causing me to run out of disc space. How do I undo the action safely? Theoretically, I’d think running (Unix) rm -r on the dir and then redo’ing the checkout for the correct path would work but I don’t want to risk causing potential alterations to the repo itself. I can’t seem to find anything online that explains how to remove checked out files from local view only. Guidance appreciated.
You can just delete your local CVS checked out files. Nothing on the CVS repository will be changed. The CVS repository is only changed when you do a cvs commit command (and cvs tag and a few other CVS commands).
You can also move your local checked out files to another directory.
Related
IPython Notebook has been opening lots of temporary folders, including those ending with .ipynb[some random chars] and folders with checkpoints.
I guess some of them were created when my compyter crashed or all sort of things happened. I would have assumed those files would clean themselves once everything is normally saved, but they don't. They keep being there, trashing my workspace.
Is it safe to delete those files and folders, once I've saved my original .ipynb file?
Thanks
It works like any other checkpoint-systems. They are always safe to delete, but you never know when you will need them, which is why they are created.
An interesting question could be how you can disable the whole checkpoint system.
It is safe to delete those files(.ipynb_checkpoints) after saving your progress to the main file
This files are there as a backup but you can delete it if it is cluttering your workspace
So I am doing a project for my school but the problem is my school computers run deep freeze. Is there any way I can use SVN and make a directory a working copy without checking out? Does anyone know how SVN remembers if a directory is a working copy? Is there some config file I can save on my network drive?
Thanks
SVN knows if the directory is a working copy by the presence of a hidden .svn directory which contains information about the working copy.
As far as a working copy without checking out, I think what you can do is do a checkout with empty depth. So from the SVN command line:
svn checkout http://url/to/repository trunk --depth empty
This will make a working directory with nothing in it, and you can later do an update to actually pull the content.
I've setup a build process using Gruntjs, but don't want anyone to be able to store the output (all contained in a build/ directory) in source control. Don't Repeat Yourself n such.
I've currently got a pre-commit hook setup that cleans the build/ directory and fails the commit if there are any unstaged files (I also stash then unstash so intentionally unstaged files won't interfere with this check).
It would be more user friendly to fail at the point a build file is added: git add build/.... But I can't seem to find an example commit hook for git add. I looked at http://git-scm.com/book/ch7-3.html and http://githooks.com/.
Is this possible? If not, can you think of an improvement over my current setup?
One of those moments where the answer comes to you as you're typing it out.
I can simply setup my .gitignore to forget build/, then also use the clean in the precommit hook to double check that no build files were added.
I uninstalled and reinstalled my WAMP earlier today. I backed up my /www directory but totally forgot about my database (phpmyadmin). I didn't delete my C:/wamp directory, i just reinstalled on top of it.
Does this mean my databases are gone forever? Is there a way to retrieve them? Next time i'll know to export a dump of my databases before I meddle with the installation, I guess I had to learn this the hard way...
Thanks for your help.
That depends if you deleted the data directory or not. By default, wamp's data directory is c:/wamp/bin/mysql/mysql5.x.x/data check there and see if you have some folders with the names of your old databases. In those folders there would be a bunch of .frm, .MYD, and .MYI files assuming you are using myisam. If those files exist then you can recover. Just make sure the datadir in my.ini is pointing to the directory where your database are and restart mysql. It should fix itself automatically.
If you use innodb tables then it's a little more complicated but can be done. Those would be stored in files named ibdata1, ibdata2, etc.
If you don't have any of those files then I'm afraid you're out of luck.
I was able to retrieve mine on windows 7 by doing the following
Open Computer by clicking the Start button , and then clicking Computer.
Navigate to the folder that used to contain the file or folder c:/wamp/bin/mysql/mysql5.x.x/data
Copied it just in case I needed to revert
Right-click it, and then click Restore previous versions. ...
Double-click a previous version of the folder that contains the file or folder you want to restore.
I have been reading the rsync documentation for a few hours, but I can't figure out how to convey to rsync how to only rename (and not re-upload folder and it's content) destination folders when they are renamed at the source.
I'm connecting to the destination with SSH, and the local folder is the source -- and the remote server is the destination. If I rename a folder containing files, rsync automatically re-uploads all the content of the source folder. I'm not using the rsync's server part, maybe it will works if were to do that ?
I have encountered the same behavior with lftp, and this tool doesn't seem's to have these options. Even if it is based on the file's date rule, files inside the renamed folder are removed/re-uploaded.
Thanks in advance if someone knows how to manage this :)
I've been looking for something similar.
so far, the best solution I have found is at:
http://serenadetoacuckooo.blogspot.com/2009/07/rsync-and-directory-renaming.html
It basically mentions including a meta-file in each folder that indicates the folder's name.
Essentially, you would want to check that file with the directory name, and rsync only if they are the same (otherwise, issue a remote rename command.)
It depends on the scope of what you're using rsync for, but I hope that this information can help you.
How would rsync or any other program know what constitutes renamed? What if two directories are very similar candidates and somehow rsync guesses maybe either one could be a rename of what went before? It's not possible. I think you're stuck with uploading everything again.
You know about the --delete option, right:
--delete delete files that don't exist on the sending side
Note also the --force option:
--force force deletion of directories even if not empty