Mir wrote:I'm copying tens of thousands of files (of varying sizes, some up to several gigabytes) to and no files containing these characters will copy:
\ / : * ? | < >
Also included in this list are the tab, space, and newline characters.
I need a bash script that will go through every file and folder in a specified directory and those directories within it, replacing each of those characters with an underscore when and where they are found.
It probably isn't a good idea to rename both the files and the folders at the same time, so make that two scripts, one for each.
xxxxxxxx ~ # aptitude show pyrenamer
Automatically installed: no
Maintainer: Ubuntu Developers <email@example.com>
Uncompressed Size: 754 k
Depends: gconf2 (>= 2.28.1-2), python (>= 2.4), python-support (>= 0.90.0), python-gtk2 (>= 2.4),
python-glade2, python-hachoir-metadata | python-eyed3, python-gconf
Description: mass file renamer written in PyGTK
You can rename files using patterns, search and replace, substitutions, insert or delete text,
or even rename files manually. You can also rename images using their EXIF tags and music using
their internal tags.
Mir wrote:I figured it out after some research. FAT partitions don't allow certain characters. I was copying to a FAT32 partition.
Caja wouldn't let me paste to Ext4 partitions without root access, and doing a paste from root with Caja often corresponded with a memory leak in either the plugin manager in Firefox or mate-system-daemon. Caja also would use 4 gigabytes of RAM and 100% of one core of my CPU if I pasted anything greater than about 8 gigabytes to any external hard drive. The solution for me was to switch to a different file manager and use an EXT4 partition (NTSF will fail if you remove it without first ejecting it). This was problematic because gnome-disk-utility wouldn't allow me to modify partitions on any of my external hard drives, so I had to dig up an old EXT4 hard drive, disassemble a case for it, swap it out with the existing external hard drive, and reassemble the case.
As it stands I'll reinstall my OS or a different one, to get away from gnome, mate, and systemd. I never had any of these problems until systemd made it into debian testing. Bye, Mint!
Users browsing this forum: No registered users and 1 guest