Make right-click "rename" work for disk labels

Bug #388207 reported by Aleve Sicofante
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
One Hundred Papercuts
New
Undecided
Unassigned
nautilus (Ubuntu)
New
Wishlist
Ubuntu Desktop Bugs

Bug Description

Binary package hint: nautilus

Go to "Computer" to see list of available volumes. Right click on any of them. Choose "Rename". The system will allow you to edit the name of the volume but when you push the enter key you'll always get an "Operation not supported by backend" message.

I think renaming a volume should do the following:

1- Ask for administrative permissions.
2- Unmount the volume if it is mounted.
3- Check for the file system in place.
4- Use the appropriate command to change the volume label.
5- Mount the file system back if it was mounted before.

This should work for all types of disks and volumes.

Alternatively, labeling might be done on a per-user basis by keeping a list of volume names at the users home folder with the correspondence between the real name and the user-given name.

Why:
If we're talking about real renaming, ordinary users should not be required to know how to use a bunch of different command line tools to change the name of a disk, or start a partition editor application to do such renaming.

If we're talking about per-user naming, two users might want to call partitions differently.

To the devs:
Take the easiest approach, but make "right clicking to rename" functional.

Revision history for this message
Aleve Sicofante (sicofante) wrote :

This is not a duplicate of bug #68924, please fully read both beyond the title before marking it as a duplicate.

Revision history for this message
A. Walton (awalton) wrote :

This is a duplicate of the other bug. You're just being slightly more specific on how you'd like to see it implemented. Either way it amounts to changing volume labels on devices (disks/usb drives/etc), which we aren't quite able to do yet, though DeviceKit-disks gets us much closer.

Furthermore, please read the Papercut guidelines.
A paper cut is:
    * Very easy to fix.
A paper cut is not:
    * A new feature. If it requires writing more than a few lines of code, or adds any new visual elements to an interface, it’s probably not a paper cut.

This will require more than just a few lines of code, in more than one project (Nautilus, GVFS and DeviceKit-disks will all need patches).

Revision history for this message
Aleve Sicofante (sicofante) wrote :

I disagree, (the other bug has issue with an MP3 player, I'm talking broader here) but as usual with Ubuntu, you're the powerful man and I'm just a user, so it really doesn't matter what I think or what I reason with you, right? :-(

The problem is as easy to fix as explained. As a matter of fact, doing the exact steps in a terminal does do the trick, so a simple script would probably do it as well.

It is VERY EASY TO FIX and IS NOT A NEW FEATURE (the feature has been lying right there, in the menus, for years).

So it is indeed a papercut (which guidelines I read carefully well before posting). But then again, who am I to disagree with the Ubuntu Powerpuff Boys?

Revision history for this message
David Siegel (djsiegel-deactivatedaccount) wrote :

Although the case in question deals with mp3 players, the proposed solution to Bug #68924 is to allow renaming volumes on right click:

"Effectively in windows you right click on the player icon and hit rename and the player retains that name when you plug into any machine"

Is this not what you want? If this is what you want, please mark your bug a duplicate of Bug #68924; if this is not what you want, please explain how what you want is different.

"but as usual with Ubuntu, you're the powerful man and I'm just a user, so it really doesn't matter what I think or what I reason with you, right? :-(... But then again, who am I to disagree with the Ubuntu Powerpuff Boys?" is not helpful, Aleve. Who do you mean by "you guys"? The people fixing this bug are users just like you. We are not ignoring your reasons or belittling you, we just don't understand how your bug is different from Bug #68924.

Revision history for this message
A. Walton (awalton) wrote :

>So it is indeed a papercut (which guidelines I read carefully well before posting). But then again, who am I to disagree with the Ubuntu Powerpuff Boys?

If you're going to insult me for actually doing work on Nautilus, you can at *least* call me a GNOME powerpuff boy, since I help maintain Nautilus for GNOME, and not just Ubuntu ;). But hey, what could I _possibly_ know about the problems involved with this bug? Please provide this very simplistic patch so that I can apply it to Nautilus' code base immediately. Thanks.

Revision history for this message
Aleve Sicofante (sicofante) wrote :

>>Although the case in question deals with mp3 players, the proposed solution to Bug #68924 is to allow renaming volumes on right click:

>>"Effectively in windows you right click on the player icon and hit rename and the player retains that name when you plug into any machine"

>>Is this not what you want? If this is what you want, please mark your bug a duplicate of Bug #68924; if this is not what you want, please explain how what you want is different.

The scope in Bug #68924 is quite narrow and the explanation doesn't even propose a solution. I accept that the end result of solving the issue might be the same for both bugs, but I also understand that the other bug sounds like a particular side annoyance that doesn't affect too many users, while my description shows that there's a much broader need for this to be fixed. If marking "my" bug as a duplicate of the other makes it "invisible" along with the proposed solution, that's bad for the community. If there's one and only one bug to describe the problem and proposing a solution, the definitely that's not Bug #68924. Just mark that other one as a duplicate!

>>The people fixing this bug are users just like you.
No you're not, as long as you have the power to hide, ignore or any other way decide about my ideas/proposals/opinions.

>>We are not ignoring your reasons or belittling you, we just don't understand how your bug is different from Bug #68924.
I thought the explanation was good enough at the very description of the bug, but I hope I have explained it further now.

A. Walton wrote 1 minute ago: (permalink)
>>If you're going to insult me for actually doing work on Nautilus, you can at *least* call me a GNOME powerpuff boy
Granted: GPB ;-) Not an insult. Just a funny remark.

>>Please provide this very simplistic patch so that I can apply it to Nautilus' code base immediately. Thanks.
I hope there's no need to repeat -again, again, again- not every Ubuntu/Gnome/Linux user is a programmer. I've described a procedure in five simple steps ("simplistic" is *your* insult, I guess). As far as I know, implementing a Nautilus script doing them sholdn't be rocket science and well inside the scope of the "papercut" idea.

Of course, fixing it in a "deeper" way might involve recoding some pieces of the system, but since this is not going to happen (the problem has been there for years now), any simplistic approach is way better than no approach at all.

Revision history for this message
Josh Leverette (coder543) wrote :

I am voting for this one, but we are forgetting... you cannot request new features in "One Hundred Paper Cuts."

Revision history for this message
Aleve Sicofante (sicofante) wrote :

The feature has been there for ages. It just doesn't work. So: it's a fix and belongs to "One Hundred Paper Cuts", since it's as simple as a Nautilus script (someone knowing Nautilus better might even attach that script to the "Rename" menu entry and voila!)

Revision history for this message
Sebastien Bacher (seb128) wrote :

the change required there doesn't seem trivial, is the volume naming something standard or something which needs to understand the filesystem in use? is there any system api to do that or only command line tools? calling a command in a graphical software in usually the best way to do things especially if you need to get feedback on the change

Revision history for this message
A. Walton (awalton) wrote :

We basically need to expose DeviceKit-Disks (FilesystemSetLabel() specifically) throughout the whole gvfs->gio->nautilus stack.

But as it's been stated a half a dozen times, and by Aleve himself [I accept that the end result of solving the issue might be the same for both bugs], this is a duplicate.

Revision history for this message
Aleve Sicofante (sicofante) wrote :

>>We basically need to expose DeviceKit-Disks (FilesystemSetLabel() specifically) throughout the whole gvfs->gio->nautilus stack.
Would you please explain why the simple solution I have provided wouldn't work?

I may understand your wish to make things more "elegantly", but perfect is usually the enemy of "good". While we wait for that perfect solution (which hasn't come in years, I insist), my proposal is a nice bandaid. It's not casual that bandaids have been used as part of the logo for the "One Hundred Paper Cuts" project

>>But as it's been stated a half a dozen times, and by Aleve himself [I accept that the end result of solving the issue might be the same for both bugs], this is a duplicate.

No matter how stubbornly you misinterpret my words, "duplicate" this is not. Again: go and mark as duplicate the other bug if you wish. Its scope is much narrower and that's why a solution to this bug will also solve the other bug. That doesn't make them duplicates.

Revision history for this message
Aleve Sicofante (sicofante) wrote :

>>is the volume naming something standard or something which needs to understand the filesystem in use?
Non-standar. That's why there's step #3 in my proposed solution.

>> is there any system api to do that or only command line tools?
There's probably both. My solution relies on command lines only, so it can be used in a simple script. Here are the command lines needed:

To check file system type: mount or fdisk
To change label:
- For FAT16 and FAT32 partitions, use mtools.
- For NTFS partitions, use ntfsprogs.
- For ext2, ext3, or ext4 partitions, use e2label.
- For JFS partitions, use jfs_tune.
- For ReiserFS (v3) partitions, use reiserfstune.
- For XFS partitions, use xfs_admin

(from https://help.ubuntu.com/community/RenameUSBDrive)

If you're asking yourself why I don't go ahead and code it myself: I was a programmer like 20 years ago. I knew my system well (IRIX) and I knew my languages well (C and C-shell), but I've been away from programming for more than 15 years. That's why I sort of "know" my solution is possible and workable. However I don't see myself doing it because my knowledge of Linux and bash programming is very limited and my practice is non-existent.

Now that I think of it, before step #1 there's actually a step #0 required: check if the action is being done on a file or a file system. Renaming files is directly supported by Nautilus. In that case no need to replace the default action for "Rename". If it's a file system, then go ahead with the script to change the disk label.

Revision history for this message
Sebastien Bacher (seb128) wrote :

wrapping around command lines doesn't seem an elegant and reliable way and we will not build workaround in softwares installed by default that would not deserver our users

Revision history for this message
Sebastien Bacher (seb128) wrote :

The difference with bug #68924 is still not clear they are both asking for volumes renaming

Changed in nautilus (Ubuntu):
assignee: nobody → Ubuntu Desktop Bugs (desktop-bugs)
importance: Undecided → Wishlist
Revision history for this message
Aleve Sicofante (sicofante) wrote :

>>wrapping around command lines doesn't seem an elegant and reliable way and we will not build workaround in softwares installed by default that would not deserver our users

I will not, by any means, dictate what you have to build or not, but I hope at least you agree that serving the users with an "Operation not permitted" is far far less elegant than building a quick workaround that does the job.

>>The difference with bug #68924 is still not clear they are both asking for volumes renaming

It's OK. I won't fight it any longer. Do as you wish and choose the bugs you fancy. Just let me insist: you want to put a bandaid to this papercut or do you prefer to endlessly wait for major surgery?

It's up to you guys.

Revision history for this message
David Siegel (djsiegel-deactivatedaccount) wrote :

I've marked this a duplicate, and added to the description:

"From duplicate bug #388207, I add emphasis that volumes should be re-namable using right-click. This may be obvious, but "let the record show" that volumes should act like all other files with respect to renaming."

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.