IRC log for #gllug on 20081102

00:00.09j0nr'16\ Over\ And\ Over\ Again.m4a'
00:01.02Discordianhmm i wonder why cp is grumbling then
00:02.22j0nrremove quotes, same issue
00:03.08DiscordianOn anything serious I've worked on spaces in filenames are a remove user issue
00:03.47Discordianbut media files tend to have em
00:05.02j0nrso, quotes dont work, escaping spaces dont work...both combined dont work
00:05.47Discordiansee what wetherin said above
00:06.06Discordianyou've got the skills now
00:06.26Discordianyou'll have to experiment
00:07.02j0nrindeed i will....
00:07.10j0nrthank you for your time... i really appreciate it
00:11.15j0nrit doesnt make sense.. if i just individually run mv 'filename' destination it works... so single quotes without escaping spaces works in the mv command on its ow
00:11.19j0nrn
00:12.11j0nrits as if it isnt recognising the `cat list` as one item per line...
00:12.34Discordianyou cat list to see
00:13.18j0nri am using : for file in `cat m4aleft` ;do cp "$file" leftovers/ ; done
00:14.13Discordianmaybe you need " instead of ' in the list
00:15.27j0nrerm... how do i sed 's/$'/"/g'
00:15.35wethrinIFS="\n" for file in `cat m4aleft`; do cp "$file" leftovers/ ; done
00:15.35j0nrtoo many quotes i hink
00:16.09Discordianahh those pesky newlines
00:16.21wethrinAnd the pesky spaces
00:16.54Discordianbring back sysfs 14 chars max
00:16.56j0nrwhat is IFS="\n"? something to do with newlines
00:17.11Discordian\n is newline
00:17.22Discordianline feed
00:17.28wethrin8 characters is enough for anyone!
00:17.48wethrinIFS = Internal Field Separator
00:17.53Discordianinput field seperator
00:18.02Discordianwot he said
00:18.06j0nrunexpected tokens?
00:18.09j0nrI did
00:18.17*** join/#gllug nixofortune_ (n=egor@87.127.26.43)
00:18.54j0nrbash: syntax error near unexpected token `do'
00:20.31wethrinthat shouldn't happen
00:20.37Discordianpulling teeth is easier than this
00:20.46j0nrheh
00:21.27j0nrwhat about cat list | xargs something or other?
00:21.31Discordianwhat shell are you using?
00:22.09wethrinj0nr: If you convert the newlines to NULs, you could get away with it
00:22.10wethrinBUT
00:22.27j0nrbash i think...
00:22.28wethrinxargs puts the thingy at the end of the command
00:22.40wethrinWhereas that's not what you want with cp
00:24.20wethrinSo you could have a little shell script along the lines of:
00:24.26wethrin#!/bin/sh
00:24.28wethrinDEST=$1
00:24.31wethrinshift
00:24.40wethrincp $* $DEST
00:24.42wethrin<PROTECTED>
00:24.52wethrinAnd do:
00:25.24wethrincat list | tr "\n" "\0" | xargs -0 ./mycp
00:25.32wethrincat list | tr "\n" "\0" | xargs -0 ./mycp leftovers/
00:25.35wethrin(even)
00:26.00wethrinMight need "\000"
00:26.16nixofortune_wethrin: you should start online bash classes :)
00:26.45j0nrwhats the DEST for?
00:26.54*** join/#gllug nixofortune (n=egor@87.127.26.43)
00:26.54wethrinDestination directory
00:28.03j0nram i putting my own destinnation directory in there or literally DEST
00:28.25wethrinWell.
00:28.36wethrinIf you just literally DEST, it's more flexible
00:28.47wethrinYou could just hardcode your destination, so it'd be:
00:28.53wethrin#!/bin/sh
00:28.58wethrincp $* leftovers/
00:28.58wethrin<PROTECTED>
00:29.04wethrinAnd then
00:29.09wethrincat list | tr "\n" "\0" | xargs -0 ./mycp leftovers/
00:30.38j0nrdo i need a done or something at the end?
00:30.44wethrinNo
00:31.04j0nrso how is that working?
00:31.51wethrinIt uses NUL as a separator, rather than spaces
00:32.21j0nrcp: missing destination file operand after `leftovers/'
00:32.42wethrinhm
00:33.53j0nrwhats the ./mycp?
00:34.45Discordianyou need to 'export DEST'
00:35.06wethrinIt's the script I pasted above
00:35.27j0nraye so do i just stick it in
00:35.32j0nras you wrote it
00:35.45wethrinYes
00:35.46j0nrjust thought it might be referring to some location
00:36.49j0nr... cant you just cp "cat m4aleft" leftovers/
00:36.52j0nrif you know what i mean
00:37.27wethrinIt'd be nice. But having spaces in filenames is troublesome
00:37.41wethrinOtherwise it'd be a lot easier
00:39.15j0nreven surrounded by quotes?
00:40.15wethrinyeah
00:44.11j0nrright... getting too tired now
00:44.28j0nrthank you ever so much for your help... no doubt i will return to bug you more soon :)
00:46.05Discordiana more radical solution would have involved editing the directory and s/ /_/g
00:49.15j0nrexec < listoffiles
00:49.15j0nrwhile read x ; do somecommand "$x"
00:49.18j0nrdone
00:49.33j0nrhmm tahat nearly worked.... it read each line as a whole...but then got:
00:49.48j0nrcp: missing destination file operand after `"20 Days Like This.m4a"'
00:50.03j0nrsomecommand = cp
00:50.21j0nrhmm where do i sepcify the destination in that?
00:50.34Discordianbecause the filename has a " inside it
00:51.10j0nryup just spotted that
00:51.15Discordianwhich matches the " of "$x
00:52.06Discordianstill it's the way to learn
00:52.25j0nrlooking promising
00:52.32j0nrwhat is exec anyway?
00:53.27Discordianoverlays the process with it's child
00:53.54Discordiansource rather than exec is what you want
00:54.04j0nrseems to be working...
00:55.16j0nri dont know how
00:56.03Discordianexecuting in a subshell
00:56.55j0nrgot there in the end :)
00:56.56j0nrthank you
00:57.04j0nrright definately good night this time
00:57.37Discordiannight
02:40.45*** join/#gllug boudicca (n=boudicca@88-108-93-143.dynamic.dsl.as9105.com)
02:41.02Discordianwb
04:44.30*** join/#gllug z00dax_ (n=kbsingh@tantra.karan.org)
04:47.01Discordianwb
05:49.56morsingz00dax_!
05:50.00morsingboudicca!
06:27.45*** join/#gllug Leeds (n=richardc@n219073033070.netvigator.com)
06:32.49morsingLeeds!
08:48.55*** join/#gllug sabinef72 (n=sabinef7@ns.popipo.fr)
11:05.24morsingsabinef72!
11:44.22morsingAnyone awake?
12:14.23*** join/#gllug Provito (n=Provito@pdpc/supporter/sustaining/Provito)
12:16.59morsingProvito!
12:25.39morsingboudiccas!
12:56.59morsingBeer
13:14.38boudiccassnuff
13:19.21morsingFoot long chilli dog
13:19.27morsingz00dax!
13:49.41mindbendrmorning
13:50.07mindbendrhttp://news.bbc.co.uk/1/hi/wales/7702913.stm
14:24.22*** join/#gllug sabinef72 (n=sabinef7@ns.popipo.fr) [NETSPLIT VICTIM]
14:24.22*** join/#gllug j0nr (n=j0nr@5acc9dcc.bb.sky.com) [NETSPLIT VICTIM]
14:24.22*** join/#gllug mikejw_ (n=mike@falcor.vm.bytemark.co.uk) [NETSPLIT VICTIM]
14:24.22*** join/#gllug cpufreak (n=cpu@nurburgr.ing.me.uk) [NETSPLIT VICTIM]
14:24.22*** join/#gllug pawel (i=t0tal@ep09.pld-linux.org) [NETSPLIT VICTIM]
14:24.22*** join/#gllug antiphase (n=ant@plasma.ossified.net) [NETSPLIT VICTIM]
14:41.00*** join/#gllug blight__ (n=blight@83.244.128.126)
14:41.04*** join/#gllug blight (n=blight@droid.gotadsl.co.uk)
15:12.38*** join/#gllug catalyst (n=catalyst@allegro/user/angelchild)
15:15.41*** join/#gllug slemarie (n=slemarie@87-194-54-71.bethere.co.uk)
15:16.32slemariesneaks in
15:17.43morsingslemarie!
15:17.47morsingcatalyst!
15:19.04slemarieI'm only here to convert you all to Maclaren supporters for the next few hours..
15:19.25slemarieThey use penguins, cheer for them!
15:29.42*** join/#gllug boudicca (n=boudicca@88-108-20-177.dynamic.dsl.as9105.com)
16:28.25*** join/#gllug blight (n=blight@droid.gotadsl.co.uk)
16:41.12*** join/#gllug Stephmw (n=steph@host81-152-201-15.range81-152.btcentralplus.com)
16:45.50morsingblight!
16:45.52morsingStephmw!
16:54.55*** join/#gllug Discordian (n=clive@chills.demon.co.uk)
18:49.18*** join/#gllug dick_turpin (n=dick_tur@dsl82-163-112-79.as15444.net)
18:49.34morsingdick_turpin
18:49.35morsing!
18:57.57*** part/#gllug dick_turpin (n=dick_tur@dsl82-163-112-79.as15444.net)
20:14.10*** join/#gllug Stephmw (n=steph@host81-152-201-15.range81-152.btcentralplus.com)
20:15.39morsingStephmw!

Generated by irclog2html.pl Modified by Tim Riker to work with infobot.