Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Mon 22 Dec 2014, 12:19
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Desktop
Icepipes - my pipe menus collection for icewm
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 3 [35 Posts]   Goto page: 1, 2, 3 Next
Author Message
Nathan F


Joined: 08 Jun 2005
Posts: 1760
Location: Wadsworth, OH (occasionally home)

PostPosted: Sun 21 Jul 2013, 04:09    Post subject:  Icepipes - my pipe menus collection for icewm  

Four cool pipe menus for icewm, all using sh rather than python or perl. These add some extra functionality and access to your root menu.

iceplaces.sh - Mimics the gnome places menu, complete with gtk bookmarks and a recent files list.

icedate.sh - Shows a calendar and the current date/time. Works best with a monospace font. The least useful one of the bunch but still cool.

icempd.sh - Control music player daemon from the menu. Requires a running mpd and the mpc command line client.

icefb.sh - Walk the directory tree from a menu. I use it on the toolbar. Open a filemanager or terminal in a given directory, or open any file that "xdg-open" understands. The terminal must understand the --working-directory= option (gnome-terminal, xfce4-terminal, lxterminal, maybe others). This could be hacked a bit for better portability.

These are WIP ports of my own openbox pipe menus. The scripts all have a user configuration section to set things like your favored external programs. To install, edit the configuration section with a text editor and place in your $PATH. Then add something similar to the following to your icewm menu:
Code:
menuprogreload Places user-bookmarks 0 iceplaces.sh

Where menuprogreload tells icewm to create a menu using this script, Places is the label you want the menu to have, user-bookmarks is the icon, 0 means "refresh this menu every time it's opened", and the name of the script is the command to execute.

Feedback welcome. These are also available in a similar form for pekwm and openbox.


=======================================
UPDATE - version 0.3 uploaded
=======================================


Version 0.3
iceplaces.sh
* ROX-Filer bookmark support
* Bugfix for better rox support (removal of 'file://' from uri's)
* Now catches removable media mounted in /media or the new /run/media via udev
* Bugfixes for various path mangling corner cases (spaces and special chars in pathnames)

Version 0.2
* Support for a browsable home directory in iceplaces.sh (calls icefb.sh).
* Supports opening urxvt from icefb.sh and can now scroll upwards in icefb.sh
icepipes-0.3.tar.bz2
Description 
bz2

 Download 
Filename  icepipes-0.3.tar.bz2 
Filesize  4.21 KB 
Downloaded  268 Time(s) 
icepipes-0.2.tar.bz2
Description 
bz2

 Download 
Filename  icepipes-0.2.tar.bz2 
Filesize  3.84 KB 
Downloaded  267 Time(s) 
icefb.jpg
Description  The icefb.sh file browser open, displaying a portion of my music collection.
jpg

 Download 
Filename  icefb.jpg 
Filesize  203.96 KB 
Downloaded  320 Time(s) 
icepipes-0.1.tar.bz2
Description 
bz2

 Download 
Filename  icepipes-0.1.tar.bz2 
Filesize  3.65 KB 
Downloaded  267 Time(s) 

_________________
Bring on the locusts ...

Last edited by Nathan F on Thu 25 Jul 2013, 19:53; edited 2 times in total
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger 
musher0


Joined: 04 Jan 2009
Posts: 4465
Location: Gatineau (Qc), Canada

PostPosted: Mon 22 Jul 2013, 11:03    Post subject:  

Hi, Nathan F.

Various reactions come rushing to the surface: Smile
* It's about time!
* That should put icewm back in the wm race.
* Many thanks!
* Only four pipemenu scripts? Smile

Best regards.

musher0

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
Nathan F


Joined: 08 Jun 2005
Posts: 1760
Location: Wadsworth, OH (occasionally home)

PostPosted: Mon 22 Jul 2013, 11:27    Post subject:  

Quote:
* Many thanks!

Quite welcome.
Quote:
* Only four pipemenu scripts?

Got a specific request? I might be game Very Happy

Icewm's menu framework is about the easiest to work with of any wm IMO. It's even smart enough to ignore entries, and in fact entire submenus, if the corresponding programs aren't in your $PATH.

To get the same functionality out of openbox required quite a bit more code and some strange workarounds. The directory browser gagged on any file or directory names containing the '&' character, for instance (which is quite common in my music collection dammit).

I've always though icewm was overlooked. It's fast as hell, had pipe menus for quite some time, can be controlled completely from the keyboard if you desire, etc. What I think is missing are nice themes that don't look like Motif or Win95, particularly in the default install.

_________________
Bring on the locusts ...
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger 
Nathan F


Joined: 08 Jun 2005
Posts: 1760
Location: Wadsworth, OH (occasionally home)

PostPosted: Mon 22 Jul 2013, 12:44    Post subject:  

Minor updates.

icefb.sh - can now browse to a parent directory, and supports using urxvt
iceplaces - supports making $HOME browsable by calling icefb

As before, set options by editing the configuration block in the scripts.

I also have a wallpaper setting pipe menu for pekwm and openbox, that I could port to icewm. Any takers?

_________________
Bring on the locusts ...
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger 
musher0


Joined: 04 Jan 2009
Posts: 4465
Location: Gatineau (Qc), Canada

PostPosted: Mon 22 Jul 2013, 15:42    Post subject:  

Nathan F wrote:
What I think is missing are nice themes that don't look like Motif or Win95, particularly in the default install.


Wrong! http://box-look.org/index.php?xcontentmode=7311&PHPSESSID=06423378e98d85123bf0a23bd2cc2c06 Cool Laughing

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
Nathan F


Joined: 08 Jun 2005
Posts: 1760
Location: Wadsworth, OH (occasionally home)

PostPosted: Mon 22 Jul 2013, 15:53    Post subject:  

Yeah, I've snagged a few from there. I was thinking if a few more attractive themes were included with the release tarball, or if they put together a collection of extra themes, people might not so easily get scared off when they install it and start thinking "this looks too retro..."
_________________
Bring on the locusts ...
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger 
musher0


Joined: 04 Jan 2009
Posts: 4465
Location: Gatineau (Qc), Canada

PostPosted: Mon 22 Jul 2013, 15:58    Post subject:  

Nathan F wrote:
I also have a wallpaper setting pipe menu for pekwm and openbox, that I could port to icewm. Any takers?


Not me... That's quite a surprising offer from the author of an excellent wallpaper setter, isn't it?! Surprised Unless of course you can outdo yourself in the form of a new icewm pipe-script? Twisted Evil Or maybe you're trying to do away with ROX?

On a tangent subject, the latest pekwm offers a snapshot utility. But with SFR's "Take-a-shot", and probably a dozen more snapshot utilities that have been generated on/for Puppy, it falls short. Maybe on other distros, though. Or for the fun of it! But as I implied, that particular need has already been catered to.

Keep 'em coming, though!

I believe that a pipe-script within the icewm menu which could reach the most obscure parts of the Puppy hierarchy (sub-sub-sub-folders, for ex.) in a somewhat thematic fashion would be most useful for beginners and developers alike. It would speed up access tremendously.

TWYL.

musher0

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
musher0


Joined: 04 Jan 2009
Posts: 4465
Location: Gatineau (Qc), Canada

PostPosted: Mon 22 Jul 2013, 16:06    Post subject:  

Nathan F wrote:
Yeah, I've snagged a few from there. I was thinking if a few more attractive themes were included with the release tarball, or if they put together a collection of extra themes, people might not so easily get scared off when they install it and start thinking "this looks too retro..."


True. But AntiX has nice icewm themes by default.
Who's "they"? Why not "we"? Smile

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
Nathan F


Joined: 08 Jun 2005
Posts: 1760
Location: Wadsworth, OH (occasionally home)

PostPosted: Mon 22 Jul 2013, 16:31    Post subject:  

Quote:
Not me... That's quite a surprising offer from the author of an excellent wallpaper setter, isn't it?! Unless of course you can outdo yourself in the form of a new icewm pipe-script? Or maybe you're trying to do away with ROX?

I don't use Puppy exclusively anymore, actually not for quite some time. I alternate between FreeBSD and Arch, and mess with Puppy out of habit and fun. So I like to program with portability in mind. Not to mention the fact that Barry has talked about making Puppy a little less dependent on Rox-Filer in his blog. Plus the fact that Rox hasn't been updated in quite some time, which is getting a bit scary.

Quote:
I believe that a pipe-script within the icewm menu which could reach the most obscure parts of the Puppy hierarchy (sub-sub-sub-folders, for ex.) in a somewhat thematic fashion would be most useful for beginners and developers alike. It would speed up access tremendously.

Something like the "places" script, but customized for Puppy? Or maybe add in support for Rox-Filer bookmarks to the iceplaces.sh script? Either of those would be reasonably easy. Or maybe a configuration variable in the iceplaces script where you could add custom directories?

Quote:
On a tangent subject, the latest pekwm offers a snapshot utility. But with SFR's "Take-a-shot", and probably a dozen more snapshot utilities that have been generated on/for Puppy, it falls short. Maybe on other distros, though. Or for the fun of it! But as I implied, that particular need has already been catered to.

The wallpaper setter pipe-menu works particularly well in pekwm, incidentally. Pekwm can configure the size of icons on a per-submenu basis, so you can display a 64x40 thumbnail preview (for instance) and actually see what it is you're setting. The downside is in it's current form it opens slow the first time, as it's working hard to scale all the images into preview size.

Quote:
Keep 'em coming, though!

I posted the openbox scripts earlier today, and the pekwm varients are almost finished. Just got the file browser working right under pekwm. I'll try to post those tommorrow.

My other thoughts are as follows.

If this grows any more, it would be worthwhile to move the configuration to a separate file (maybe ~/.config/pipemenusrc or the like) and think of them as a suite of programs. That way any customizations would apply to all of the scripts, and also accross all supported WM's.

That strategy means less editing of the scripts, and it can be done on a per-user basis meaning that the scripts can be in /usr/bin and each user can choose they'ds own preferred apps for integration with their own desktop (thinking again of portability to other distros/os's).

That strategy also opens the possibility of creating a gui tool to set prefs, although I don't want to promise something that I may not have the time or inclination to write.

_________________
Bring on the locusts ...
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger 
Nathan F


Joined: 08 Jun 2005
Posts: 1760
Location: Wadsworth, OH (occasionally home)

PostPosted: Mon 22 Jul 2013, 16:41    Post subject:  

For amusement, and to show the wallpaper menu in pekwm...

The screenshot shows my development model. I'm running openbox on my desktop and have another window with pekwm running via Xephyr (nested X server) so I can catch any error messages easily while testing things out.

Kinda crazy I know. But it works for me. This kind of flexibility is what I love about *nix.
insanity.jpg
 Description   
 Filesize   103.02 KB
 Viewed   468 Time(s)

insanity.jpg


_________________
Bring on the locusts ...
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger 
musher0


Joined: 04 Jan 2009
Posts: 4465
Location: Gatineau (Qc), Canada

PostPosted: Tue 23 Jul 2013, 01:21    Post subject:  

Hello again, Nathan.

Can you give more detail as to how to hook the iceplaces.sh script properly in the regular menu?

I added this line to the icewm menu and nothing happens :
Code:
prog "iceplaces" - /root/.icewm/iceplaces.sh


Thanks in advance.

Also line 2 of the iceplaces script should read:
Code:
# Simple places script for your icewm menu

in the icewm version, should it not?
(And not refer to pekwm, obviously...)

Best regards.

musher0

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
Nathan F


Joined: 08 Jun 2005
Posts: 1760
Location: Wadsworth, OH (occasionally home)

PostPosted: Tue 23 Jul 2013, 04:07    Post subject:  

For the latest versions of icewm -
Code:
menuprogreload "iceplaces" - 0 /root/.icewm/iceplaces.sh


And yes, I missed that when I ported it over from pekplaces.sh.

_________________
Bring on the locusts ...
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger 
musher0


Joined: 04 Jan 2009
Posts: 4465
Location: Gatineau (Qc), Canada

PostPosted: Tue 23 Jul 2013, 11:13    Post subject:  

Quote:
Code:
menuprogreload Places user-bookmarks 0 iceplaces.sh

Where menuprogreload tells icewm to create a menu using this script, Places is the label you want the menu to have, user-bookmarks is the icon, 0 means "refresh this menu every time it's opened", and the name of the script is the command to execute.


I'll be getting new reading glasses shortly... Confused Sorry for having missed that.

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
musher0


Joined: 04 Jan 2009
Posts: 4465
Location: Gatineau (Qc), Canada

PostPosted: Tue 23 Jul 2013, 12:00    Post subject:  

Hello, again, Nathan.

iceplaces.sh displays the entries when introduced with the menuprogreload command in the menu.

However, here are a few suggested edits to make it work with ROX-Filer in Puppy :

Code:
#!/bin/sh
# Simple places script for your pekwm menu
# 06.20.2013 by Nathan Fisher (nfisher dot sr at gmail)
# Edits by Christian L'Écuyer (aka musher0), July 23, 2013,
# for use with ROX-Filer on PuppyLinux.
#
#  This program is free software; you can redistribute it and/or modify
#  it under the terms of the GNU General Public License as published by
#  the Free Software Foundation; either version 2 of the License, or
#  (at your option) any later version.
#
#  This program is distributed in the hope that it will be useful,
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#  GNU General Public License for more details.
#
#  You should have received a copy of the GNU General Public License
#  along with this program; if not, write to the Free Software
#  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
#  MA 02110-1301, USA.
#
#####################################################
# User configuration section

# What file manager are we using...
# Affects display of network:// and trash:// uri's
# filemanager="nautilus"
# filemanager="thunar"
# filemanager="pcmanfm"
filemanager="rox"
# Edited by m0

# End config
####################################################

# Static places menu
cat << EOF
prog "Filesystem" "drive-harddisk.png" $filemanager /
# file:/// # Edited by m0
prog "Home" "user-home.png" $filemanager $HOME
# file://$HOME # Edited by m0
# prog "Network" "network-workgroup.png" $filemanager network:///
# Edited by m0 # Where is that network folder on a Puppy ?
prog "Trash" "user-trash.png" $filemanager ~/.Trash
# trash:/// # Edited by m0

separator

EOF

while read bookmark
do
  SETNAME="$(echo $bookmark | cut -s -f 2- -d ' ')"
  if [ ! "$SETNAME" = "" ] ; then
    LABEL="$SETNAME"
    bookmark=$(echo $bookmark | cut -f 1 -d ' ')
  else
    LABEL="$(basename $bookmark)"
  fi
  echo "prog $LABEL folder.png $filemanager ${bookmark}"
done<$HOME/.gtk-bookmarks
cat << EOF
separator
menu Recent document-open.png {
EOF

for uri in $(grep "href=\"file" ${HOME}/.local/share/recently-used.xbel \
    | tail -n 10 | cut -f 2 -d '"' | sed 's%file://%%') ; do
# This grep and cut, etc. should be redone with ROX in mind. # Edited by m0
# Consider: # grep file:/// | tail -n15 | cut -d "\"" -f 2  # Suggested by m0
 if [ -f "${uri}" ]; then
  echo -n "prog \"$(basename ${uri})\" - "
 else
  echo -n "prog \"* $(basename ${uri})\" - "
 fi
 echo "defaulthandler ${uri}"
# xdg-open # works so-so if at all on Puppy. Prefer defaulthandler.
done
cat << EOF
separator
prog "Clear Recent Documents" edit-clear.png echo > ${HOME}/.local/share/recently-used.xbel
}
EOF


Suggestions are based on my own take on the openbox "Recent files" pipemenu, adapted to aemenu (from aewm).

Now if I can remember where I put it on this board... I'll reference it! Confused

Bye for now.

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
musher0


Joined: 04 Jan 2009
Posts: 4465
Location: Gatineau (Qc), Canada

PostPosted: Tue 23 Jul 2013, 12:13    Post subject:  

Just an idea:
on first run of iceplaces.sh perhaps ask the user which file manager (s)he is using, make that into a flag file in /tmp. Then provide variants of the building part as
case "`cat /tmp/fm`" in
rox) blabla ;;
x) bleble ;;
y) blibli ;;
and so on
esac

_________________
"Logical entities must not be multiplied needlessly." / "Il ne faut pas multiplier les êtres logiques inutilement." (Ockham)
Back to top
View user's profile Send private message Visit poster's website 
Display posts from previous:   Sort by:   
Page 1 of 3 [35 Posts]   Goto page: 1, 2, 3 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Desktop
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1115s ][ Queries: 13 (0.0048s) ][ GZIP on ]