Thread View: news.software.readers
2 messages
2 total messages
Started by Ohmster
Tue, 04 Oct 2005 05:09
[newspost] how to order files being posted?
Author: Ohmster
Date: Tue, 04 Oct 2005 05:09
Date: Tue, 04 Oct 2005 05:09
67 lines
4308 bytes
4308 bytes
(Sorry for posting this twice, I think that this post gets the gist of what help I need. Thank you for your tollerance.) I needed a nice, lightweight Usenet poster for Linux and discovered newspost through google here: http://newspost.unixcab.org/ There is a totally excellent HOW-TO page for newspost here: http://ebook.23ae.com/documents/newspost_howto.html I have a fedora core 3 system and could not find a newspost 2.1.1 rpm file so I found an earlier src rpm, edited and used the spec file from that src rpm, and use rpmbuild to create newspost-2.1.1-1.i386.rpm from the current tarball, newspost-2.1.1.tar.gz. Worked like a champ, the program installed nicely, works fine, and the man page is excellent, with examples (The examples help a real lot.) I use newspost to post a large file to Usenet and WinRAR to break it down into 15Mb parts, then use QuickPar to create the par2 files, create an info or index file, and newspost does the rest. I am using a wildcard at the end of the command like, *, to post all the files in the current directory, this is great, but I would like more control over the order of the files that are posted though, e.g.: Post in this order: sfv file nfo or index file all rar archive files, beginning with part one: mymovie.part01.rar, ending with mymovie.part49.rar all par2 files in order: mymovie.vol000+01.PAR2 to mymovie.vol155+40.PAR2 What happens is that my files are not posted this way, I get par2 files in the middle of posting and the index.jpg at the very end of the large post. Not good, I need the index to be the first file and the par2 files at the end. Instead of this: newspost -c checksum.sfv -n alt.binaries.test -s 'Here is a great movie' /nfs/video/* Can I do something like this: newspost -c checksum.sfv -n alt.binaries.test -s 'Here is a great movie' <file-list.txt> (Above lines are wrapped by the newsreader, all should be on one line.) Where I tell newspost to use a text file, file list, as to what files to post and in what order? I was able to do this with autopost32 for windows and it worked great, autopost32 created a files.bbs file which was a text file it created automatically and you could edit or "sort" if you wanted to as to place the files to be posted in the desired order. autopost32 would even allow comments next to each file in the file list that would show up in the subject for that particular file when it was posted (This is not important, having control of the posting order is.) Is anything like this possible for newspost 2.1.1? Is there some workaround otherwise, shell script or some sort of regex for the command line then? -- ~Ohmster "Read Ohmster" in subject, bypass spam filter. ohmster /a/t/ newsguy dot com
Re: how to order files being posted?
Author: Anonymous via the Cypherpunks To...
Date: Mon, 17 Oct 2005 10:36
Date: Mon, 17 Oct 2005 10:36
65 lines
3225 bytes
3225 bytes
Hi Ohmster,
I am reposting this reply in news.software.readers because
you may not have seen my original reply in alt.linux.
Instead of cross-posting in news.software.readers and
alt.linux, it might have been better to post once in
comp.os.linux.misc because newspost is not a newsreader and
because comp.os.linux.misc has more traffic than alt.linux
(IMHO).
I was a bit confused by your post in another way. You say
you are running FC3 (a version of Red Hat Linux), but you
mention using QuickPar and WinRar. These programs sound
like Windows applications: they are certainly not available
for my Linux distro. Instead, I run par2cmdline, rar and
unrar which are all built as Linux apps and can be scripted
(which seemed to be what you were trying to achieve).
With all that out of the way, here is my tentative answer to
your original query.
I am also learning newspost, and would like to do the same
as you. The trick may be to build up an ordered list of
files in an environment variable. For example, if the local
directory contains two files file.1 and file.2, then you can
control the order in which these files are presented to
newspost as follows (using Bash).
declare FILE_LIST="file.1 file.2"
newspost <options> $FILE_LIST.
For the opposite order, simply do this.
declare FILE_LIST="file.2 file.1"
newspost <options> $FILE_LIST.
Perhaps you could try this as an experiment and see if the
order is preserved in the actual posting. (I haven't got
posting rights ATM.)
If it does work, you'll then need to create an appropriate
$FILE_LIST variable automatically. It might be something as
simple as this (but adapted for your data).
declare FILE_LIST=\
"$(ls *PAR2; ls file.dat.???; ls *vol;)"
newspost <options> $FILE_LIST.
You may need fancier quoting if your file names contain spaces
or other weird characters, but we'll keep it simple until we
know it works.
You can always debug the variable using this.
echo "$FILE_LIST"
Please post your whole script in news.software.readers if
you succeed.
HTH,
Angelika
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads