jetcareers

Go Back   jetcareers > General > Forum Tech Support

Closed Thread
 
Thread Tools Display Modes
Old April 13th, 2006, 19:29   #1
Doug Taylor
Agent Smith
 
Doug Taylor's Avatar
 
Join Date: Dec 1969
Location: KSDL
Posts: 39,931
Blog Entries: 1
Send a message via AIM to Doug Taylor Send a message via Skype™ to Doug Taylor
Default Unix/Pine gurus

When my MySQL database went down this morning, I was doing some command-line crap and decided to load up "pine" since I was already in shell.

so I've got 18,232 messages in my inbox. I'm not even kidding.

Does anyone know of a 'bulk delete' command in pine?
__________________
Doug Taylor
http://76school.flyblog.com (old!)
http://30west.flyblog.com (updated 11/28)
Doug Taylor is offline  
Old April 14th, 2006, 01:57   #2
Bandit_Driver
Old Skool
 
Bandit_Driver's Avatar
 
Join Date: Oct 2003
Location: DTW
Posts: 1,677
Send a message via MSN to Bandit_Driver
Default Pine's "Aggregate Command Set"

Doug This may help:

Pine's "Aggregate Command Set"

Pine has a very powerful feature called the "aggregate command set", which makes it possible to select a group of messages based on something they have in common (date range, number range, subject line, to line, from line, text in the message, etc.), and then apply a command to all of them (save, delete, etc.).
Turning on the Aggregate Command Set

If you do not already have the command enabled on your version of pine here is how to do so:
  1. Type m to get to the main menu of pine.
  2. Type s to bring up pine's setup menu.
  3. Type c to go to the configure menu for pine.
  4. Type ^w to bring up the "Word to find" command.
  5. In the space provided type agg to search for the line that has "enable-aggregate-command-set" on it.
  6. If there is an X next to the command in the brackets then it is already enabled. If not, then type x to enable the command.
  7. Now type e to exit the config menu.
  8. When prompted to save your changes, type y for yes to save them.
An Example, How to delete a selected group of messages

As mentioned above, there are a variety of characteristics that you can use to group messages for selection. Example:
You've received a lot of messages from a discussion list that you haven't had time to read. You want to get rid of all of those that are out of date. Let's say the list is "cheaptalk-l@somewhere.edu", and anything before December 1997 is out of date.
We're looking for two features that are common to all the messages you want to get rid of:
  • the list address, which will be text found on the To: line of every message sent to the list, and
  • the date the message was received, with respect to December, 1997.
Here's the method for isolating these messages, starting while you're in the Folder Index (message list):
  1. Make sure that you are in the message index by typing i or by typing l to select a different folder.
  2. Type ; which activates the select command.
  3. Type t which tells pine to use test for the selection criteria.
  4. Type t again which narrows the text searched to the To: line of the messages.
  5. Type cheaptalk which is the text that you want to find.
At this point, all the messages from the group will be marked at the left with an X. You could use the Z(oom) command to toggle between displaying only the selected messages and displaying all the messages. If you just wanted ALL the messages from the group, you'd be finished, but in this case, we want to NARROW the search to include ONLY the ones BEFORE December 1, 1997. So we do another selection process on the ones we've already selected:
  1. Type ; to bring up the selection menu.
  2. Now type an n in order to narrow the selection.
  3. Type a d to select messages by date.
  4. To toggle the date selection between ON, SINCE, or BEFORE, type ^w. In this case we want to select BEFORE so toggle the message until BEFORE is selected.
  5. Now type in the date 1-Dec-1997.
At this point, all the X'd items from on or after 12/31/97 become un-X'd.
Now to DO something with the selection

Our example calls for us to delete these messages. We do this by using the append command which is the other command of the aggregate command set.
  1. Type a to apply a command to the selected messages.
  2. Now type a d to mark the selected messages for deletion.
  3. To finish the delete immediately, type x to expunge the messages from the message folder.
  4. To finish the process type y for yes to expunge the messages.
And that finishes the job.
For more information about these commands

The Aggregate Command Set is even more powerful than what we've just show above. For more information about it,
  1. Type a ? to ask for help.
  2. Now bring up the search feature by typing w.
  3. In the space provided type selecting to go to the topic called selecting which covers this topic.
Check this site for more info http://helpdesk.umd.edu/topics/applications/email/
__________________

OOTSK
Logbook Pro - Electronic Pilots Logbook
Bandit_Driver is offline  
Old April 14th, 2006, 04:11   #3
aloft
Old Skool
 
aloft's Avatar
 
Join Date: Sep 2001
Location: Inside your OODA loop
Posts: 6,737
Default

cd to wherever your inbox file is....

$ cat ' ' > inbox

Problem solved.
__________________
Commercial Pilot, ASEL/AMEL/IA
Chief Pilot, aerial mapping company
Mountain-qualified Search & Rescue/Disaster Relief Mission Pilot, Civil Air Patrol
900+ TT/25 ME
B.S., Psychology, University of Utah
aloft is offline  
Old April 14th, 2006, 08:20   #4
Doug Taylor
Agent Smith
 
Doug Taylor's Avatar
 
Join Date: Dec 1969
Location: KSDL
Posts: 39,931
Blog Entries: 1
Send a message via AIM to Doug Taylor Send a message via Skype™ to Doug Taylor
Default

Sveet!
__________________
Doug Taylor
http://76school.flyblog.com (old!)
http://30west.flyblog.com (updated 11/28)
Doug Taylor is offline  
Closed Thread

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


All times are GMT -4. The time now is 17:16.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.1.0
©2008 jetcareers.com