Bug 257497 - csh does not execute for loop
Summary: csh does not execute for loop
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-07-30 02:42 UTC by bugzeo
Modified: 2021-07-30 20:38 UTC (History)
0 users

See Also:


Attachments
for execution in csh (10.71 KB, image/png)
2021-07-30 02:42 UTC, bugzeo
no flags Details
csh sript to list .dat files on current dir (41 bytes, text/plain)
2021-07-30 20:37 UTC, bugzeo
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description bugzeo 2021-07-30 02:42:41 UTC
Created attachment 226792 [details]
for execution in csh

User with default shell csh.

$ uname -a
FreeBSD freebsd 13.0-RELEASE-p3 FreeBSD 13.0-RELEASE-p3 #0: Tue Jun 29 19:46:20 UTC 2021     root@amd64-builder.daemonology.net:/usr/obj/usr/src/amd64.amd64/sys/GENERIC  amd64

Running the loop in csh results in prompt:
$ touch file1.dat file2.dat
$ foreach i (*.dat) ; echo $i ; end
foreach?
Comment 1 Andriy Gapon freebsd_committer freebsd_triage 2021-07-30 06:28:50 UTC
Both foreach and end must appear alone on separate lines.
Comment 2 bugzeo 2021-07-30 20:37:56 UTC
Created attachment 226808 [details]
csh sript to list .dat files on current dir
Comment 3 bugzeo 2021-07-30 20:38:08 UTC
Using a script works.