ronen25 / nautilus-copypath Goto Github PK
View Code? Open in Web Editor NEWA small Nautilus extension for quickly copying file/Samba paths
License: GNU General Public License v3.0
A small Nautilus extension for quickly copying file/Samba paths
License: GNU General Public License v3.0
Configuration variables I can think of ATM are:
NAUTILUS_COPYPATH_QUOTE_PATHS
- 1 to put quotes around all copied paths; otherwise 0. Default is 0.
NAUTILUS_COPYPATH_WINPATH
- 1 to display and extra option to convert Samba paths to Windows paths on-the-fly; otherwise 0. Default is 0.
Thanks for the extension. Though I cant seem to get it working. This is the error I am seeing. Thoughts?
Thanks for your time.
Traceback (most recent call last):
File "/home/clu/.local/share/nautilus-python/extensions/nautilus-copypath.py", line 49, in get_background_items
return self.get_file_items(window, files)
File "/home/clu/.local/share/nautilus-python/extensions/nautilus-copypath.py", line 44, in get_file_items
items.append(item_copy_path)
NameError: global name 'items' is not defined
Python 3.7.0-4
Python-gobject 3.30.1-3
Python2-nautilus 1.2.2-2
Nautilus 3.30.0-1
Not sure if this is fixable, but thought I should make the issue known. In order to 'cd' into a directory with parenthesis, they need to be escaped. This is how a path with () is currently copied:
/Music/Albums/Wolfmother/WOLFMOTHER\ Wolfmother\ (PBTHAL\ vinyl)
When it should be...
/Music/Albums/Wolfmother/WOLFMOTHER\ Wolfmother\ \(PBTHAL\ vinyl\)
In short, each parenthesis requires a backslash in front of it.
Thanks again for your work.
For me it'd make sense to use :
for example.
Doing this after #7 will be ideal, since it will essentially require zero additional work.
When trying to run this in a recent distro with GTK4 installed, the extension fails with the following error:
Traceback (most recent call last):
File "/home/fynn/.local/share/nautilus-python/extensions/nautilus-copypath.py", line 9, in <module>
gi.require_version('Nautilus', '3.0')
File "/usr/lib64/python3.11/site-packages/gi/__init__.py", line 117, in require_version
raise ValueError('Namespace %s is already loaded with version %s' %
ValueError: Namespace Nautilus is already loaded with version 4.0
Tested this on Fedora 38.
Thua extension is a saving-life thing for the present version of Nautilus.
One drawback for me is that it escapes spaces in filenames / pathnames when I paste them
Would it be a way to avoid this?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.