euglug.org

[작성자:] admin

  • [Eug-lug] Subject: Copying, moving, whatever… using wildcards in destination : wc2fn.py



    Ralph ZellerMon Nov 1 12:25:07 PST 2004

    Horst,
    
    I have used your program, for its wccp features, and I find it useful.
    I especially appreciate the comfort of using the '-t' option, that's a
    nice touch.  
    
    Ralph
    
  • [Eug-lug] Subject: Copying, moving, whatever… using wildcards in destination : wc2fn.py



    horstMon Nov 1 09:44:18 PST 2004

    > Date: Sun, 31 Oct 2004 13:38:05 -0800 (PST)
    > From: jgw at absent.org
    > To: Eugene Unix and Gnu/Linux User Group <euglug at euglug.org>
    > Subject: Re: [Eug-lug] Subject: Copying, moving,
    >     whatever... using wildcards in destination : wc2fn.py
    > 
    > This is all already possible with shell scripting. Shell scripting is very
    > friendly once you learn it. I recommend "UNIX Shell Programming" by SAMS
    > if you're further interested in shell programming. Or, you can do it your
    > way.
    >
    > Further in your lengthy post, you mentioned that there aren't really any
    > friendly tools, just a bunch of programs with a specific function that'll
    > let you do what you want. This is how UNIX works, it's design philosophy.
      Actually there is a perl 'rename' program in many packages --I suggest to 
    read the documentation of it and decide for yourself how 'friendly' 
    it'susage seems to you :-) // i.e. I do read documentations
    > I always recommend to folks that, while using UNIX, they learn the UNIX
    > way, as it's the least painful route in the long run.
    >
      ...
    
    My point was not to have different shell scripts for *each* little task.
      I wanted a tool specifically to handle filename expansion, using the 
    intuitive glob style (yes, a shell feature too :-) for the destination 
    file, similar to how I match the source files. Calling it an extension of 
    glob may be far fetched, but it goes in that direction.
      By putting this all in one tool it's a snap to run commands as a test 
    first, or in the debug mode, and to provide meaningful help messages upon 
    failure, add some documentation,...
    
      *** I like to challenge you to pick about half of the examples I gave 
    (some easy/some complex) and show us the *one* shell script that does it.
      I am less interested what the script looks like (though it might be quiet 
    educational for many of us) -- I am interested in ease of use and what the 
    commandline input looks like. Concrete --not philosophical.
      The next challenge then would be to test that script against all the 
    platforms and shells I mentioned.
    
      - Horst, still thanks for feedback, also to Steve and Jacob
    P.S. I *do* write shell script when I have to.
    
    ~~~~~~~~~~~~~~ copy & reply ~~~~~~~~~~~~~~~~
    >Date: Sun, 31 Oct 2004 20:41:15 -0800 (PST)
    >From: jgw at absent.org
    ...>
    >I have to agree with Jake's reply ^^^. However, I felt I had to correct
    >the original poster when he complained (albeit quite politely) that there
    >wasn't a real solution with shell. I wanted to point out that, in fact,
    >what he said can't be done, can easily be done with a simple, albeit
    >lengthy shell script. I write shell scripts all day long every day, so I
      I thought I gave credit to 'powerful shell tools [] to handle such tasks
    (find with -exec {} ; xargs ; shell loops)  But the emphasis is on 
    *friendly*.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
  • [Eug-lug] Subject: Copying, moving, whatever… using wildcards in destination : wc2fn.py



    jgw at absent.orgSun Oct 31 20:41:15 PST 2004

    >> Very true. Another Unix philosophy is "There's always more than one
    >> right way". I guess you can't blame someone for seeing, what he feels to
    >> be, a better way and implementing it. Besides, even though some don't
    >> agree with how and why the script came to be there's probably some value
    >> in the exercise.
    >
    > oh, for sure.  I was not trying to imply that what Horst did was foolish,
    > surely he must have read some documentation somewhere along the way ...
    > unless he just has innate python ability ;)  plus, he did fully
    > describe what he was doing!
    
    I have to agree with Jake's reply ^^^. However, I felt I had to correct
    the original poster when he complained (albeit quite politely) that there
    wasn't a real solution with shell. I wanted to point out that, in fact,
    what he said can't be done, can easily be done with a simple, albeit
    lengthy shell script. I write shell scripts all day long every day, so I
    leave it to someone else to actually write out an easy-to-understand
    example.
    
    Additionally, while writing a Python script is a fascinating lesson, it's
    really just reinventing the wheel amd it's probably better to learn a more
    "native" way of doing things, ala /bin/sh. Every UNIX system has sh, and
    what you learn of shell programming exponentially helps you with solving
    other problems.
    
    I'll have to dig up the bash implementation of httpd that I wrote (yes, it
    does run out of either inetd or via netcat). It's quite a thorough
    implementation and even had the beginnings of cgi functionality (although
    I really didn't get that working before I got bored). Hopefully that
    didn't get toasted in the hd crash that took my 300 Reason sequences and
    songs with it.
    
    Others have written similarly sickening things with bash and sh. I'm
    absolutely convinced there's very little you can't do with the unix shell.
    
    
  • [Eug-lug] Configuring KDE



    Allen BrownSun Oct 31 18:53:01 PST 2004

    Excellent!  Actually, clicking on my desktop doesn't produce a menu.
    I haven't found where that is enabled.  But I worked thru the
    menus from the lower panel and found it.
    
    And I've replaced konsole with gnome-terminal.  If you are familiar
    with gnome-terminal, it launches a web browser if you C-A-left over
    a highlighted URL.  I don't think the selection of browser is in
    gnome-terminal.  Best I can tell, it is some external setting.
    Currently it is launching konquerer.  I want it to use mozilla.
    Any idea how I control that?
    --
    Allen Brown
      work: Agilent Technologies      non-work: http://www.peak.org/~abrown/
            allen_brown at agilent.com             abrown at peak.org
      I have noticed that the people who are late are often so much jollier
      than the people who have to wait for them.
    
    
    On Sun, 31 Oct 2004, Steve wrote:
    
    > On Sun, 2004-10-31 at 17:28, Allen Brown wrote:
    > > Having become disgusted with what they've done with gnome, I'm
    > > switching to KDE.  But there is something that I find rather annoying.
    > > 
    > > There is a menu bar across the top of the screen.  I don't need what
    > > it offers.  And it just takes up valuable screen real estate.  How
    > > can I nuke it?
    > 
    > Right click on the desktop and click "Configure Desktop..."
    > 
    > Click on "Behavior" and select the "None" radio button under "Menu Bar
    > at Top of Screen"
    > 
    > _______________________________________________
    > EUGLUG mailing list
    > euglug at euglug.org
    > http://www.euglug.org/mailman/listinfo/euglug
    > 
    
  • [Eug-lug] Configuring KDE



    SteveSun Oct 31 17:39:47 PST 2004

    On Sun, 2004-10-31 at 17:28, Allen Brown wrote:
    > Having become disgusted with what they've done with gnome, I'm
    > switching to KDE.  But there is something that I find rather annoying.
    > 
    > There is a menu bar across the top of the screen.  I don't need what
    > it offers.  And it just takes up valuable screen real estate.  How
    > can I nuke it?
    
    Right click on the desktop and click "Configure Desktop..."
    
    Click on "Behavior" and select the "None" radio button under "Menu Bar
    at Top of Screen"
    
    
  • [Eug-lug] Configuring KDE



    Allen BrownSun Oct 31 17:28:55 PST 2004

    Having become disgusted with what they've done with gnome, I'm
    switching to KDE.  But there is something that I find rather annoying.
    
    There is a menu bar across the top of the screen.  I don't need what
    it offers.  And it just takes up valuable screen real estate.  How
    can I nuke it?
    --
    Allen Brown
      work: Agilent Technologies      non-work: http://www.peak.org/~abrown/
            allen_brown at agilent.com             abrown at peak.org
      If the only tool you have is a hammer, you tend to see every problem
      as a nail. --- Abraham Maslow
    
    
  • [Eug-lug] Subject: Copying, moving, whatever… using wildcards in destination : wc2fn.py



    Jacob MeuserSun Oct 31 17:03:56 PST 2004

    On Sun, Oct 31, 2004 at 03:13:02PM -0800, Steve wrote:
    > On Sun, 2004-10-31 at 13:54, Jacob Meuser wrote:
    > > On Sun, Oct 31, 2004 at 01:38:05PM -0800, jgw at absent.org wrote:
    > > 
    > > > Further in your lengthy post, you mentioned that there aren't really any
    > > > friendly tools, just a bunch of programs with a specific function that'll
    > > > let you do what you want. This is how UNIX works, it's design philosophy.
    > > > I always recommend to folks that, while using UNIX, they learn the UNIX
    > > > way, as it's the least painful route in the long run.
    > > 
    > > heh, the UNIX way is RTFM.  IMO it's very sad (and extremely annoying)
    > > that people complain that they have to read before doing :(
    > 
    > Very true. Another Unix philosophy is "There's always more than one
    > right way". I guess you can't blame someone for seeing, what he feels to
    > be, a better way and implementing it. Besides, even though some don't
    > agree with how and why the script came to be there's probably some value
    > in the exercise.
    
    oh, for sure.  I was not trying to imply that what Horst did was foolish,
    surely he must have read some documentation somewhere along the way ...
    unless he just has innate python ability ;)  plus, he did fully 
    describe what he was doing!
    
    -- 
    <jakemsr at jakemsr.com>
    
    
    > 
    > _______________________________________________
    > EUGLUG mailing list
    > euglug at euglug.org
    > http://www.euglug.org/mailman/listinfo/euglug
    
  • [Eug-lug] Subject: Copying, moving, whatever… using wildcards in destination : wc2fn.py



    Jacob MeuserSun Oct 31 16:57:27 PST 2004

    On Sun, Oct 31, 2004 at 04:32:04PM -0800, jgw at absent.org wrote:
    > Well no, the previous versions WERE piss poor in performance. But 3.5 and
    > 3.6 are really speedy (again, on my few boxen). Anyhow, I'm really sold on
    > it, now. Tons of cool features, pf and systrace are godly :)
    > 
    > It sounds like they're going to change the biglock deal, they're just
    > taking it one step at a time.
    > 
    
    "time" being the key word there, he he he
    
    -- 
    <jakemsr at jakemsr.com>
    
  • [Eug-lug] Subject: Copying, moving, whatever… using wildcards in destination : wc2fn.py



    jgw at absent.orgSun Oct 31 16:32:04 PST 2004

    Well no, the previous versions WERE piss poor in performance. But 3.5 and
    3.6 are really speedy (again, on my few boxen). Anyhow, I'm really sold on
    it, now. Tons of cool features, pf and systrace are godly :)
    
    It sounds like they're going to change the biglock deal, they're just
    taking it one step at a time.
    
    
    > could say I told ya so, but ...
    >
    > anyway, 3.6 is out now.  has SMP on i386 and amd64, but still biglocked.
    >
    > --
    > <jakemsr at jakemsr.com>
    > _______________________________________________
    > EUGLUG mailing list
    > euglug at euglug.org
    > http://www.euglug.org/mailman/listinfo/euglug
    >
    
    
    
  • [Eug-lug] Subject: Copying, moving, whatever… using wildcards in destination : wc2fn.py



    Jacob MeuserSun Oct 31 15:15:32 PST 2004

    On Sun, Oct 31, 2004 at 02:57:37PM -0800, jgw at absent.org wrote:
    > If people aren't into RTFMing, there are plenty of other operating systems
    > to suit them. RTFMing beats writing up some whacky Python script. Although
    > one can easily argue that's an interesting little learning hack, as well.
    > 
    > PS: I can't really badmouth OpenBSD about its lack of speediness anymore.
    > Been running 3.5 on a few boxes and whatever they've done the past few
    > revs, performance has really increased (on my hadware, anyways). I'm now
    > using OpenBSD on my formerly FreeBSD boxes (two of them, that is).
    
    could say I told ya so, but ...
    
    anyway, 3.6 is out now.  has SMP on i386 and amd64, but still biglocked.
    
    -- 
    <jakemsr at jakemsr.com>