Path Monitor

by VenKamikaze

UUID: path-monitor@kamikaze
Score: 4
Last edited: 2 days ago
Last commit: df89907c9ae17da833f2bb5948e8a132ce79d9de



Quick access files in a directory

I used code from various applets as I couldn't find great doco on the web. I ended up finding some decent stuff from the GNOME3 site though, at least for the GSettings stuff.

I looked through the code in the following applets to help me learn what to do, and in some cases may have used some small segments of code from these applets:

  • weather@mockturtl
  • bluetooth@cinnamon.org
  • trash@cinnamon.org
  • xrandr@cinnamon.org

The weather applet was clear that it's licence was GPL3, so the licence for this applet will fall under GPL3 too (incase I used some code from there, not sure anymore).

I also retrieved the really nice looking icon from: http://findicons.com/icon/94179/previewer?width=16 Icon Author: http://schollidesign.deviantart.com/

The icon is also GPL licenced. I wanted to use it, but after 15 minutes of trying to figure out how to display a bundled icon with the applet, I gave up.

Please drop me a note if you know a nice way of doing that!

You can reach me on e-mail at (remove the whitespace and convert the AT etc): mick saunders+path-mon AT gmail dot com

Thanks!


14 Comments

-
4 years ago
Perfect!
-
4 years ago
I've updated the applet to a newer version (0.9). It now has a right click context menu to allow easy configuration. You should find it much easier to configure now.
-
4 years ago
Correction - the multi-instance support works fine, filtering isn't finished yet.
-
4 years ago
"I've also enabled multi-instance support and basic file filtering." Both things work perfectly. "Hopefully this makes the applet a bit more useful for you." I'm sure it's not just me it will be useful for - it's an excellent app!
-
4 years ago
I've just done a release. I tested it on a clean Mint-Cinnamon 14.1 LiveDVD and wasn't able to reproduce needing to hold down the mouse button when entering the directory the first time. I've also enabled multi-instance support and basic file filtering. Both of these options require manual configuration right now (displayed in the applet description), but I'll look at making them configurable settings at some stage. BTW I re-wrote the original multi-instance support that I did over the weekend that I described as "nasty" ! Hopefully this makes the applet a bit more useful for you.
-
4 years ago
"my implementation was ... nasty" - well that's honest! I'll wait and see what you decide. "I'll sort out the file filtering" That would be useful.
-
4 years ago
So I started writing something which ended up as a bit of a mess to try and hack in multi-instance applets into Cinnamon. I've decided to hold off on releasing this as my implementation was ... nasty, and I then noticed this patch recently merged into Cinnamon to support multi-instances properly: https://github.com/linuxmint/Cinnamon/pull/1439 - Haven't decided what I'll do now as I'm not sure how long this will take to be released and if it will make it into the different cinnamon distros reasonably fast. In the meantime though I'll sort out the file filtering functionality and at least get that out there.
-
4 years ago
Didn't quite have time to finish my changes, I'll look at this again on the weekend.
-
4 years ago
K said: "OK what I might do is look at modifying the code base to make it easier to support multiple instances, and for handling file filtering a bit easier." C says: That was what I was hoping for of course, but I thought it was too much to ask! K Said: "At this stage..." C says: That makes sense. K said: "...looking through the code..." C says: Well I can write programs in other languages so it was worth a quick look. I thought I'd worked out the difference between Java and Javascript but obviously not!...........The idea of being able to get at your commonly used files fast is great, as even "favourites" or "recently used files" take more clicks and selections and I am constantly adding very minor things to my most-used files. I have a couple of related ideas which I'll suggest if you are interested but they are possibly off-topic here so email chrisofbristol gmail com if you are interested.
-
4 years ago
OK what I might do is look at modifying the code base to make it easier to support multiple instances, and for handling file filtering a bit easier. At this stage I'll probably just put some basics into the code but not make a method for entering it easily for the user, and then expand on it later. Then I can do a release and give you simpler instructions to do what you want. I'm at work at the moment, but I'll see what I can do tonight. Cheers for your feedback Chris!

BTW I think it's great that you're looking through the code. Good attitude to try and scratch your own itch :) Just a note though - the applet is written in javascript, not java. Ignore the similarities in the name - they're really quite different. I'd like it to be in java - I'm actually more proficient in that language :)
-
4 years ago
I am using Linux Mint-14/Cinnamon. I only need to hold down the mouse button until I have entered one character. I'm not sure what sort of settings you mean...... You are right, the directory is lost - I hadn't got round to correcting my post. I wondered about a constant I saw called watchedpath but don't know what I'm doing so I left well alone! Multiple instances would be very useful, so please do post the instructions you mention......In an attempt to get rid of the hidden files I've been trying to see how the filelist is selected and found this fragment (child_info = files.next_file(null, null)) != null) and changed the last null to '*.~' but it didn't like it!
I assume there is a simple way to do this. I hope you will excuse my reluctance to learn Java.
-
4 years ago
Chris - I'm surprised you mentioned that you needed to hold down your left mouse button to enter the directory. What distro and version are you running? Have you changed any particular settings that mean you need to hold the mouse button when looking at context menus etc?

Making a copy of the applet should work fine until you restart cinnamon. On restart the second copy (path-monitor2) might not load the entered path. If this happens you probably need to modify the gschema to handle another "watchedpath" and recompile it, and then point the path-monitor2 at this other 'watchedpath' key. If you really want to get multiple instances to work I can post some more detailed instructions.
-
4 years ago
So good I want two! One for each of the two directories I use most. I copied the applet's directory to another called "path-monitor2@kamikaze" and changed any occurrence of "path-monitor" in the names or contents of the files to "path-monitor2". Works fine, but I know nothing about Java - so it's at you own risk!
-
4 years ago
I am going to try this as it could be useful. It's a bit difficult to enter the directory name as you have to hold down the left button at the same time. Once you've entered it, you can change it by editing the line at the top of the popup menu. It would be nice to be able to deselect hidden files.