Re: curl - sys env vars in a curl statement

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08Aug2016 16:36, Joe Zeff <joe@xxxxxxx> wrote:
On 08/08/2016 04:32 PM, cs@xxxxxxxxxx wrote:
On 08Aug2016 16:18, Joe Zeff <joe@xxxxxxx> wrote:
On 08/08/2016 04:12 PM, Cameron Simpson wrote:
>1aa.lwp

on its own. The shell will open and trucate it, then close it, running
no command. Thus, an empty file.

No.  What you will get is this:

bash: laa.lwp: command not found

What you need is this:

touch laa.lwp

You must have a very weird shell. I've been doing this literally for
decades. Works perfectly.

I see the difference: I'd left out the redirection, which made laa.lwp into a command. Thanx for the correction, because that's an elegant way to create an empty file.

Also:

 >>file        # safety create file (doesn't truncate it)
 </dev/rst0    # rewind tape drive
 </dev/nrst0   # fast forward tape to next file
 >/dev/rst0    # write termination file to tape, then rewind
               # (convention: empty file indicates end of tape)

and of course the "exec" with no command variation for opening files by the current shell and not letting go:

 exec 3>>logfile   # attach fd 3 to a log file from now on
 ... script stuff ...
 echo blah >&3     # write to log
 ... script stuff ...
 exec 3<&-         # close log file

etc.
Cheers,
Cameron Simpson <cs@xxxxxxxxxx>
--
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://lists.fedoraproject.org/admin/lists/users@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux