-
 KDE-Apps.org Applications for the KDE-Desktop 
 GTK-Apps.org Applications using the GTK Toolkit 
 GnomeFiles.org Applications for GNOME 
 MeeGo-Central.org Applications for MeeGo 
 CLI-Apps.org Command Line Applications 
 Qt-Apps.org Free Qt Applications 
 Qt-Prop.org Proprietary Qt Applications 
 Maemo-Apps.org Applications for the Maemo Plattform 
 Java-Apps.org Free Java Applications 
 eyeOS-Apps.org Free eyeOS Applications 
 Wine-Apps.org Wine Applications 
 Server-Apps.org Server Applications 
 apps.ownCloud.com ownCloud Applications 
--
-
 KDE-Look.org Artwork for the KDE-Desktop 
 GNOME-Look.org Artwork for the GNOME-Desktop 
 Xfce-Look.org Artwork for the Xfce-Desktop 
 Box-Look.org Artwork for your Windowmanager 
 E17-Stuff.org Artwork for Enlightenment 
 Beryl-Themes.org Artwork for the Beryl Windowmanager 
 Compiz-Themes.org Artwork for the Compiz Windowmanager 
 EDE-Look.org Themes for your EDE Desktop 
--
-
 Debian-Art.org Stuff for Debian 
 Gentoo-Art.org Artwork for Gentoo Linux 
 SUSE-Art.org Artwork for openSUSE 
 Ubuntu-Art.org Artwork for Ubuntu 
 Kubuntu-Art.org Artwork for Kubuntu 
 LinuxMint-Art.org Artwork for Linux Mint 
 Arch-Stuff.org Art And Stuff for Arch Linux 
 Frugalware-Art.org Themes for Frugalware 
 Fedora-Art.org Artwork for Fedora Linux 
 Mandriva-Art.org Artwork for Mandriva Linux 
--
-
 KDE-Files.org Files for KDE Applications 
 OpenTemplate.org Documents for OpenOffice.org
 GIMPStuff.org Files for GIMP
 InkscapeStuff.org Files for Inkscape
 ScribusStuff.org Files for Scribus
 BlenderStuff.org Textures and Objects for Blender
 VLC-Addons.org Themes and Extensions for VLC
--
-
 KDE-Help.org Support for your KDE Desktop 
 GNOME-Help.org Support for your GNOME Desktop 
 Xfce-Help.org Support for your Xfce Desktop 
--
openDesktop.orgopenDesktop.org:   Applications   Artwork   Linux Distributions   Documents    LinuxDaily.com    Linux42.org    OpenSkillz.com   
 
Artwork
News
Groups
Knowledge
Events
Forum
People
Jobs
Register
Login



Sponsoring


-
- Content .- Fans  .- Knowledge Base  . 

Clean Backup Files

   1.0.2  

KDE Service Menu

Score 50%
Link:  http://
Minimum required   KDE 3.2.x
Downloads:  1050
Submitted:  Jun 22 2004
Updated:  Jun 22 2004

Description:

This servicemenu contains two actions for directories:

"Delete backup files": deletes all files matching *~ in the selected directories.

"Move backup files to Trash": moves all files matching *~ to the Trash




Changelog:

1.0.2: Don't panic if a directory contains no backup files. Also, put the actions in a submenu. These fixes courtesy of Micha Scholl.

1.0.1: small improvement to install script.

1.0: Initial release




LicenseGPL
Send to a friend
Subscribe
Other  Artwork  from LMCBoy
Report inappropriate content



-
.

 seeking advice on er

 
 by LMCBoy on: Jun 22 2004
 
Score 50%

Hello,

I'm the author of cleanbak. Please be aware that if you try to move backup files to Trash on a directory in which there are no backup files, you'll get some bizarre error message about the mv command not being recognized. I believe this error message appears because mv throws an error if the source file does not exist. I need to avoid or suppress this error, so that konqueror doesn't panic.

So, I have been trying for a few hours to write an Exec command using bash to check whether backup files exist before trying to move them, but I have not been successful. Here is my latest unsuccessful attempt:

Exec=/bin/sh -c 'path=%u; t=$path/*~; if [ $t != "$path/*~" ]; then mv -f $path/*~ ~/Desktop/Trash 2>/dev/null; fi'

So, if backup files exist, then t is a space-separated list of the backup files. If no backup files exist, then t is assigned the literal string "$path/*~" (with $path expanded). That's why I only execute the mv command if $t != "$path/*~". It's an ugly kludge, but it does work in a test shell script I wrote. It just doesn't work in the cleanbak.desktop file:
the mv command is never attempted, whether backup files exist or not.

If anyone has advice or ideas on how to make it work properly, please let me know!


Reply to this

-

 Re: seeking advice on er

 
 by sarahb523 on: Jun 22 2004
 
Score 50%

you can use something like that:
[ -e filename ]&& mv -f filename /mytrash


Reply to this

-
.

 Re: Re: seeking advice on er

 
 by LMCBoy on: Jun 22 2004
 
Score 50%

No, this does not work if the target directory contains more than one backup file. If I do something like:

if [ -e %u/*~ ]; then mv -f %u/*~ ~/Desktop/Trash; fi

as you are suggesting, then the "*" is expanded to a space-separated list of all the matching files in the directory. -e expects only one argument, so the command fails.

That's why I was trying the more convoluted statement I originally posted.


Reply to this

-

 Re: seeking advice on er

 
 by dschrader on: Jun 22 2004
 
Score 50%

What about something like:

for each in `ls -1 %u/*~`; do mv $each ~/Desktop/Trash/; done


Reply to this

-
.

 bug is fixed

 
 by LMCBoy on: Jun 22 2004
 
Score 50%

Please download 1.0.2. Thanks to Micha Scholl, it will no longer complain when the target directory doesn't contain backup files.

Thanks Micha!


Reply to this

-
.

 install.sh

 
 by hayjay on: Jul 28 2004
 
Score 50%

There is a little Problem in the way the script generates the installation paths.

On some Systems like my suse box the
call of

kde-config --localprefix

may result in a path with appending / so that you will have a // in the complete path

the following after the generation of complete paths will fix this:

PGLOBAL=${PGLOBAL/'\/\/'/'/'}
PLOCAL=${PLOCAL//'\/\/'/'/'}
KDIALOG=${KDIALOG//'\/\/'/'/'}


greetings
Hajo

Reply to this

-
.

 Re: install.sh

 
 by LMCBoy on: Aug 2 2004
 
Score 50%

Thanks for the fix. Isn't it true that a double // in a path is harmless, though?


Reply to this

-

 Re: Re: install.sh

 
 by hayjay on: Aug 20 2004
 
Score 50%

it seems that you are right

but i think there must be a problem without the fix but i do not remember what it was

cu
Hajo


Reply to this

Add commentBack






-

-
How do you like Plasma 5?
 The best KDE Desktop ever.
 Definitely a nice improvement.
 Not decided yet. Haven't tried it yet.
 I do not like some of the changes.
 KDE is taking the wrong way.
 I am still sticking with KDE 3.5.
 I have no opinion, but wanted to vote anyway.

resultmore




 
 
 Who we are
Contact
More about us
Frequently Asked Questions
Register
Twitter
Blog
Explore
Artwork
Jobs
Knowledge
Events
People
Updates on identi.ca
Updates on Twitter
Facebook App
Content RSS   
News RSS   
Discussion RSS   
Events RSS   

Participate
Groups
Forum
Add Artwork
Public API
About KDE-Look.org
Legal Notice
Spreadshirt Shop
CafePress Shop
Advertising
Sponsor us
Report Abuse
 

Copyright 2001-2014 KDE-Look.org Team  
All rights reserved. KDE-Look.org is not liable for any content or goods on this site.
All contributors are responsible for the lawfulness of their uploads.
KDE and K Desktop Environment are trademarks of KDE e.V.