Git Product home page Git Product logo

coreutils's Introduction

These are the GNU core utilities.  This package is the union of
the GNU fileutils, sh-utils, and textutils packages.

Most of these programs have significant advantages over their Unix
counterparts, such as greater speed, additional options, and fewer
arbitrary limits.

The programs that can be built with this package are:

  [ arch b2sum base32 base64 basename basenc cat chcon chgrp chmod chown
  chroot cksum comm coreutils cp csplit cut date dd df dir dircolors dirname
  du echo env expand expr factor false fmt fold groups head hostid hostname
  id install join kill link ln logname ls md5sum mkdir mkfifo mknod mktemp
  mv nice nl nohup nproc numfmt od paste pathchk pinky pr printenv printf ptx
  pwd readlink realpath rm rmdir runcon seq sha1sum sha224sum sha256sum
  sha384sum sha512sum shred shuf sleep sort split stat stdbuf stty sum sync
  tac tail tee test timeout touch tr true truncate tsort tty uname unexpand
  uniq unlink uptime users vdir wc who whoami yes

See the file NEWS for a list of major changes in the current release.

If you obtained this file as part of a "git clone", then see the
README-hacking file.  If this file came to you as part of a tar archive,
then see the file INSTALL for general compilation and installation
instructions, or README-install for system and coreutils specific instructions.

Like the rest of the GNU system, these programs mostly conform to
POSIX, with BSD and other extensions.  For closer conformance, or
conformance to a particular POSIX version, set the POSIXLY_CORRECT
and the _POSIX2_VERSION environment variables, as described in
the documentation under "Standards conformance".

The ls, dir, and vdir commands are all separate executables instead of
one program that checks argv[0] because people often rename these
programs to things like gls, gnuls, l, etc.  Renaming a program
file shouldn't affect how it operates, so that people can get the
behavior they want with whatever name they want.

Special thanks to Paul Eggert, Brian Matthews, Bruce Evans, Karl Berry,
Kaveh Ghazi, and François Pinard for help with debugging and porting
these programs.  Many thanks to all of the people who have taken the
time to submit problem reports and fixes.  All contributed changes are
attributed in the commit logs.

And thanks to the following people who have provided accounts for
portability testing on many different types of systems: Bob Proulx,
Christian Robert, François Pinard, Greg McGary, Harlan Stenn,
Joel N. Weber, Mark D. Roth, Matt Schalit, Nelson H. F. Beebe,
Réjean Payette, Sam Tardieu.

Thanks to Michael Stone for inflicting test releases of this package
on Debian's unstable distribution, and to all the kind folks who used
that distribution and found and reported bugs.

Note that each man page is now automatically generated from a template
and from the corresponding --help usage message.  Patches to the template
files (man/*.x) are welcome.  However, the authoritative documentation
is in texinfo form in the doc directory.


***************
Feature requests:
---------------

If you would like to add a new feature, please try to get some sort of
consensus that it is a worthwhile change.  One way to do that is to send
mail to [email protected] including as much description and justification
as you can.  Based on the feedback that generates, you may be able to
convince us that it's worth adding.  Please also consult the list of
previously discussed but ultimately rejected feature requests at:
https://www.gnu.org/software/coreutils/rejected_requests.html


***************
Reporting bugs:
---------------

Send bug reports, questions, comments, etc. to [email protected].
To suggest a patch, see the files README-hacking and HACKING for tips.

All of these programs except 'test' recognize the '--version' option.
When reporting bugs, please include in the subject line both the package
name/version and the name of the program for which you found a problem.

If you have a problem with 'sort', try running 'sort --debug', as it
can often help find and fix problems without having to wait for an
answer to a bug report.  If the debug output does not suffice to fix
the problem on your own, please compress and attach it to the rest of
your bug report.

IMPORTANT: if you take the time to report a test failure,
please be sure to include the output of running 'make check'
in verbose mode for each failing test.  For example,
if the test that fails is tests/df/df-P.sh, then you would
run this command:

  make check TESTS=tests/df/df-P.sh VERBOSE=yes SUBDIRS=. >> log 2>&1

For some tests, particularly perl tests, you can get even more detail by adding
DEBUG=yes. Then include the contents of the file 'log' in your bug report.


***************************************

There are many tests, but nowhere near as many as we need.
Additions and corrections are very welcome.

If you see a problem that you've already reported, feel free to re-report
it -- it won't bother us to get a reminder.  Besides, the more messages we
get regarding a particular problem the sooner it'll be fixed -- usually.
If you sent a complete patch and, after a couple weeks you haven't
received any acknowledgement, please ping us.  A complete patch includes
a well-written ChangeLog entry, unified (diff -u format) diffs relative
to the most recent test release (or, better, relative to the latest
sources in the public repository), an explanation for why the patch is
necessary or useful, and if at all possible, enough information to
reproduce whatever problem prompted it.  Plus, you'll earn lots of
karma if you include a test case to exercise any bug(s) you fix.
Here are instructions for checking out the latest development sources:

  https://savannah.gnu.org/git/?group=coreutils

For general documentation on the coding and usage standards
this distribution follows, see the GNU Coding Standards at:
https://www.gnu.org/prep/standards/

For any copyright year range specified as YYYY-ZZZZ in this package
note that the range specifies every single year in that closed interval.

Please see the file COPYING for copying conditions.

========================================================================

Copyright (C) 1998-2024 Free Software Foundation, Inc.

Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.3 or
any later version published by the Free Software Foundation; with no
Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
Texts.  A copy of the license is included in the "GNU Free
Documentation License" file as part of this distribution.

coreutils's People

Contributors

agordon avatar andreas-schwab avatar auerswal avatar benoitknecht avatar bernhard-voelker avatar bhaible avatar chenguo avatar collinfunk avatar ebblake avatar eggert avatar gigabo avatar giuseppe avatar jamesyoungman avatar jarkkojs avatar jas4711 avatar jeremy-compostella avatar jojo-schmitz avatar kdudka avatar kolayne avatar meyering avatar nickalcock avatar ovasik avatar pibroch avatar pixelb avatar slattarini avatar stephane avatar stoeckmann avatar sylvestre avatar vapier avatar ztion avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

coreutils's Issues

sort -hu

Since this only reorders two items if one is strictly greater than

When using different sorting methods such as -h[uman] combined with -u[nique] not all unique values are returned. The comments seem to indicate there is an assumption about list ordering

Use 'coreutils/bin' tools.

Hello, people!
Good day.
Before everything, I want to say: Thank you for these great tools!

I'm developing a kernel (OS), which is forked from OpenBSD.(It's like BSD, but it isn't actually.)
I want to use 'coreutils/src' tools in my project, because I think they're more complete than 'openbsd/src/bin' tools.
(I haven't changed GNU tools.)
Do I have permission to do that?

Have a nice time.

test-localeconv failed when make check about [email protected] on openEuler_aarch64

I meet a problem:test-localeconv failed when make check about [email protected] on openEuler_aarch64

Steps to reproduce the issue

[root@localhost coreutils]# make -j126 check
============================================================================
Testsuite summary for GNU coreutils 9.1
============================================================================
# TOTAL: 370
# PASS:  344
# SKIP:  25
# XFAIL: 0
# FAIL:  1
# XPASS: 0
# ERROR: 0
============================================================================
See gnulib-tests/test-suite.log

[root@localhost spack-src]# vim gnulib-tests/test-suite.log
FAIL: test-localeconv
=====================

test-localeconv.c:53: assertion 'l->frac_digits == CHAR_MAX' failed
FAIL test-localeconv (exit status: 134)

or:
[root@localhost gnulib-tests]# ./test-localeconv
test-localeconv.c:53: assertion 'l->frac_digits == CHAR_MAX' failed
Aborted (core dumped)

Can you analyze why the error is reported, or what settings I'm missing?

How to build from archive source?

If you obtained this file as part of a "git clone", then see the
README-hacking file. If this file came to you as part of a tar archive,
then see the file INSTALL for compilation and installation instructions...

got from tar archive but without file INSTALL,
where is the INSTALL ?

gnu sort completely unexpected behaviour

"Please do not send pull-requests or open new issues on Github."

  • Well as the choice seems to be between reporting it here and exposing my email address to spammers on your public mailing list, I'll report it here anyway.

The issue being reported here, is that GNU sort, does not sort, or sorts incorrectly, or sorts by weird locale rules that make it utterly useless even to people native to that locale. Results that are completely unexpected and likely to cause software written using the tool, to take completely wrong actions depending on which part of the world the software is being executed, or whether the system is using the utf-8 character set.

Quite a simple scenario - four lines of text:

"a 1"
"a2 1"
"a2 a"
"a a"

How would you expect it to be ordered, if 'sorted'?

I would expect:
a 1
a a
a2 1
a2 a

and this is indeed the result if we use a non-utf-8 locale, or if we use LC_ALL=C

$> printf "a 1\na2 1\na2 a\na a" | LC_ALL=en_AU sort
a 1
a a
a2 1
a2 a

However for UTF-8 locales, gnu sort seems to go insane:

$> printf "a 1\na2 1\na2 a\na a" | LC_ALL=en_AU.UTF-8 sort
a 1
a2 1
a2 a
a a

Questions/assumptions:

Should UTF-8 users be expecting GNU sort to sort by the second column instead of the first?

Why is GNU sort treating a space character as magically equivalent to a '2' digit?

Maybe GNU sort is treating a whitespace as a character and not a spacing token?

  • this does not seem to be the case, as the following demonstrates.

  • In the first command below, 'a2[space]' sorts AFTER 'a[space]'

  • In the second command below, 'a2[space]' sorts BEFORE 'a[space]'

  • What's the difference? Nothing in the first column. Therefore it seems GNU sort is somehow sorting based on the second column.

$> printf "a \na2 \na2 a\na " | LC_ALL=en_AU.UTF-8 sort
a
a
a2
a2 a

$> printf "a x\na2 x\na2 a\na x" | LC_ALL=en_AU.UTF-8 sort
a2 a
a2 x
a x
a x

As a developer who writes scripts which have to perform actions such as sorting lists of files and deleting some of them, is it possible for me to utilise gnu sort safely in a such a script which may (or may not) be run in a UTF-8 locale? Short of setting LC_ALL=C in every script, is there any way to make gnu sort work as expected, which is that, unless specific sort keys are specified, it should at the very least sort lines such that all the lines starting with 'a' are together, and all the lines starting with 'a2' are together - whether a locale sorts 'a' before or after 'a2' is another matter - but no locale or utf-8 setting should result in the behaviour seen above, where lines starting with 'a' are insterspersed with lines that start with 'a2', and are seemingly sorted by the second column instead of the first.

zzzzzzz error in coreutils

error: opening directory '/tmp/nix-build-coreutils-9.0.drv-0/coreutils-9.0/gt-pwd-long.sh.P4Ne/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzz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zzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz/zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz': File name too long

Repo cannot be cloned

error: object a6727941433ee1c91a20ede6cb381af1d18c566d: missingSpaceBeforeDate: invalid author/committer line - missing space before date

-ELOOP on recursive symlink. Version behavior difference.

On 8.32, When install does:
$ strace install -m 0444 -o 0 -g 0 -D "recursive softlink" ...
...
newfstatat(AT_FDCWD, "recursive softlink", 0x7ffe91a254d0, 0) = -1 ELOOP (Too many levels of symbolic links)

Which isn't really unexpected, when trying to deal with a softlink like that.

But on 9.1, the install seems to proceed just fine?
Now I know that softlinks are a POSIX rabbithole, but the difference in behavior is ... unexpected?
To me it looks like this was unintentionally "fixed" by cleaning of some code?
Anyway. I can't find a commit or a declaration of changes to behavior.
But maybe I'm just looking in the wrong place.

Why not gnu-tar

I am looking for gtar (gnu-tar?)..
tar on a mac is weird by default.
shant gnu-tar come with coreutils?
to get gtar I had to run brew install gnu-tar , I would have expected it to come with coreutils but idk

Keep the git sources in a compileable variant at all times please

I use this issue tracker even if nobody reads it. IMO github issue trackers are so much
more convenient to use, compared to oldschool email ...

Anyway.

Today I checked out the sources here via git.

Running "./configure" does not work from the git checkout though.

My next attempt was to use "autoconf".

This failed via:

sh: line 1: build-aux/git-version-gen: No such file or directory
/usr/bin/m4:configure.ac:659: cannot open `m4/cu-progs.m4': No such file or directory
autom4te: error: /usr/bin/m4 failed with exit status: 1

Would it be possible to maintain the git sources in a compileable variant at all times?
As far as I know this is the case with meson/ninja, so perhaps one could consider
abandoning GNU configure if it is such a hassle to keep the toplevel sources in a
compileable version at all times.

Note that this is the case with BOTH (!) gcc and binutils. When I do a git clone
checkout on them, I can compile both as-is, without having to do anything else,
so something is weird with coreutils. Please learn from gcc and binutils - both
projects handle this situation better, IMO.

info share of additional stress test cases for [ factor ] utility

hope you don't mind, I've taken the liberty of algorithmically coding up the primes listed in the testing scenarios for the factor utility, and also created 2 more derivative primes from the same set using combinations of string manipulations.

Feel free to incorporate these into the test cases as you see fit. Aside from gnu-gawk's template codes, I hereby declare all code shown below to be classified under [ public domain ] :

9223372036854775421
9223372036854775643
18446744073709551709
94441166490049640643114101303190314499640643114101
04346046994430930304346046940094664449905590304464482454586302332293465458630233229

       # gawk profile, created Sun Nov 27 17:55:45 2022

       # BEGIN rule(s)

       BEGIN {
     1         OFS = RS
     1     CONVFMT = "%.250g"
     1     ___=(____=(__=((_+=++_)^++_)^(_^_-_-_))-(_^_*(_+_)+_)) \
                     (_____=__-(_^_+(_+_)*(_^_-_)+(_+_)^_))        \
                     (______=__+=__+(_+(_+_^_)*_))                 \
                     (__=rev(substr("", __ = sprintf("%.f%.f", int(____*__),
                     int(_____*__)), gsub("["(_^_)(_^_*_+--_^_)"]+","",__))__))

     1     gsub("[" ((++_+_)*(_+_^_)-_) "]+","",___)
     1     print _____, ____, ______, __, rev(___)
       }

    94  function rev(___, __, _)
       {    
    94     return \
           (_+=_^=_<_)^_<(__=+__ ? +__ : length(___)) \
            ? rev(substr(___,_=int(__/-_)-+-++__),__-_) \
              rev(substr(___,_^!--_,_),_)          \
            :     substr((___)(__<=_++? "" : substr(___,_--,
                       _^_==__) substr(___,_,--_))___,__,__)
       }

and output from gnu-factor utility ::


     - 9223372036854775421: 9223372036854775421
 
     - 9223372036854775643: 9223372036854775643
 
     - 18446744073709551709: 18446744073709551709

     - 94441166490049640643114101303190314499640643114101: 94441166490049640643114101303190314499640643114101

     - 4346046994430930304346046940094664449905590304464482454586302332293465458630233229: 4346046994430930304346046940094664449905590304464482454586302332293465458630233229

files starting with "-" makes stat to say "invalid option -- 'S'"

files starting with "-" makes stat to say "invalid option -- 'S'"

example, create a file "-fddsfdf.txt" and run "stat *" or "stat -fddsfdf.txt"

and then again , create a file "fddsfdf.txt" and run "stat *" or "stat fddsfdf.txt"

In first case, it will says "invalid option -- 'S'",
in second, it will be run normally.

No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 11 (bullseye)
Release: 11
Codename: bullseye

stat (GNU coreutils) 8.32
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later https://gnu.org/licenses/gpl.html.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Command 'ls' and Wild card (?) question mark, is not displaying file names properly with 3 chars long, in bin directory

OS Version:
Linux Mint 20.3

Coreutils package version:
8-30.3ubuntu

I am trying to list file names with exactly 3 chars using the command 'ls /bin/???' in the 'bin' directory and the result returns all directories in the 'bin' directory, when it should return only files with a size of 3 chars.

I also noticed that the same command 'ls /bin/???' on Linux Mint in version 19.3 works perfectly, it returns only the files with a size of 3 chars in the 'bin' directory.

It should also be noted that in the user directories it also behaves as expected, returning only 3 chars.

Is this behavior expected or is it a bug?

Thank you.

Please help urgwnt

How i compile this script to create my own custom ( su ) binary
Please help me by provide comlig step using gcc
and other tools..

mv out of memory v9.1

When moving a folder from one zfs dataset to another zfs dataset on the same pool, mv is giving me out of memory errors.
I have lots of available ram, free -m:
total used free shared buff/cache available
Mem: 128891 81197 46663 51 1029 46377
Swap: 30500 3 30497

rsync works fine.

attached is the strace output.
mv-strace.txt

cp --reflink=always leaves a zero-length file when failing

cp --version:
cp (GNU coreutils) 9.0
Packaged by Gentoo (9.0-r2 (p0))
Copyright (C) 2021 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later https://gnu.org/licenses/gpl.html.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by Torbjorn Granlund, David MacKenzie, and Jim Meyering.

uname -a:
Linux Portal 5.15.29-gentoo-dist #1 SMP Tue Mar 22 09:57:30 GMT 2022 x86_64 Intel(R) Core(TM) i5-4440 CPU @ 3.10GHz GenuineIntel GNU/Linux

Command used (the idea was to show you can't do cross-mount reflinking yet):
cp --reflink=always /.snapshots/3616/snapshot/root/backup.sh butts

Expected:
cp: failed to clone 'butts' from '/.snapshots/3616/snapshot/root/backup.sh': Invalid cross-device link
And no file called 'butts'.
Actual:
cp: failed to clone 'butts' from '/.snapshots/3616/snapshot/root/backup.sh': Invalid cross-device link
And a zero-size file called 'butts'.

suggestions: append indicator for macos alias

  • file2-Hard Link, file3-Symbolic Link, file4-Alias
    • macos ls

      > ls -lFhAi
      total 16
      64821 -rw-r--r--  2 t_liang  staff     0B 10 25 13:53 file1
      64821 -rw-r--r--  2 t_liang  staff     0B 10 25 13:53 file2
      64827 lrwxr-xr-x  1 t_liang  staff     5B 10 25 13:53 file3@ -> file1
      64828 -rw-r--r--@ 1 t_liang  staff   1.1K 10 25 13:53 file4
      
    • coreutils ls

      > gls -lFhAi
      total 8.0K
      64821 -rw-r--r-- 2 t_liang staff    0 10 25 13:53 file1
      64821 -rw-r--r-- 2 t_liang staff    0 10 25 13:53 file2
      64827 lrwxr-xr-x 1 t_liang staff    5 10 25 13:53 file3 -> file1
      64828 -rw-r--r-- 1 t_liang staff 1.2K 10 25 13:53 file4
      
      • Q: the alias file4 not have a indicator?

  • -F, --classify: append indicator (one of */=>@|) to entries
    • Q: * mean?
    • Q: / mean?
    • Q: = mean?
    • Q: > mean?
    • Q: @ mean?
    • Q: | mean?

Please publish a new release

As others have expressed, mailing lists are antiquated to deal with. Feel free to ignore and close this whenever it's seen.


The last release was March 2020 with 8.32. That is the longest duration between a release for over a decade of coreutil releases.

Not much came up searching the web, this projects README or the resource links provided in this issue template. I did come across an old mailing list question where the answer about release cadence was "whenever it's ready"..

Is there a roadmap or related resource to get an idea of what's blocking that release? (this is a handy feature that platforms like Github or Gitlab can help with)


I'm particularly interested in the cp --reflink=auto default introduced back in June 2020 (fun fact: it's been exactly one year since this commit was made). Some distros backport this, but it'd be nicer to rely on an official release.

It can be confusing/unexpected to find that the behaviour differs between distros packaging for coreutils when the version is the same..

updated and now 'rm' does not work, command not found.

I've just updated ubuntu with sudo apt-get update and sudo apt-get upgrade -y but now when I try using the rm command it says command not found. I try sudo apt install coreutils but it's showing I'm on the latest version.

Wrong format for "date" program in LANG=id_ID.UTF-8

I'm not sure if this is translation related issues, but each time I run the "date" program the format is wrong and make me confused.

How to reproduce:

LANG=id_ID.UTF-8 date --date="2021-01-26T18:49:57+07:00"

The result:

Sel 26 Jan 2021 06:49:57  WIB

Expected result:

Sel 26 Jan 2021 18:49:57 WIB

As you can see, the result is wrong. This is off by 12 hours.

It's really frustrating if unaware user use "date" as logging program and they get incorrect result.

Additional note:

If I use LANG=id date, the result is Tue Jan 26 18:49:57 WIB 2021. It seem the time format is correct, but the language and date format is messed up.

NB: I know I can use: date +"%a %d %b %Y %T %Z" with result Sel 26 Jan 2021 18:49:57 WIB to make correct date.

Generate Single Binary File

Hello There,
There is one file named gen-single-binary.sh in build-aux, I think that this file can be used to generate a single binary file for all c files in src folder.
I tried it using the following command
sh gen-single-binary.sh path/to/coreutils/src/local.mk

I think this command runs successfully, as it prints

Automatically generated by gen-single-binary.sh.  DO NOT EDIT BY HAND!
src_libsinglebin_dir_a_DEPENDENCIES = src/libsinglebin_ls.a
src_libsinglebin_vdir_a_DEPENDENCIES = src/libsinglebin_ls.a
src_libsinglebin_arch_a_DEPENDENCIES = src/libsinglebin_uname.a
Command arch
noinst_LIBRARIES += src/libsinglebin_arch.a
src_libsinglebin_arch_a_SOURCES = src/coreutils-arch.c
src_libsinglebin_arch_a_ldadd =  src/libsinglebin_uname.a
src_libsinglebin_arch_a_CFLAGS = "-Dmain=single_binary_main_arch (int, char **);  int single_binary_main_arch"  -Dusage=_usage_arch $(src_coreutils_CFLAGS)
.. for all c files

But I am not able to find out that if binary file generated where it is? If it does not generate a binary file then how to generate a single binary file of all the c program in src directory.

Thanks

mv from gnuutils doesnt work on a mounted file system

I get the error
mv: cannot move 'filename1' to 'filename2': Function not implemented
when using mv from gnuutils on a mounted filesystem, but if i use the stock mv it works fine. I'm unsure if this issue belongs here or on the gnutils issue tracker.

bfleischer commented on Apr 5, 2022
Please raise this issue with the coreutils/gnulib team. It seems they are calling a file system operation that is not supported by the macFUSE file system you are using. I took a brief look at the relevant coreutils and gnulib code and I think the operation might be renameatx_np(). Looks like there have been some changes to the relevant gnulib code recently. It might be worth making sure you are already using the latest version before raising the issue.

osxfuse/osxfuse#881

Compiling a specific binary in this package

I want to use this code as a basis for my project. I am forking the mv command, since it's relatively simple (~500 lines of dedicated code), and its functions closely match the purpose of my program.

(In case you're curious, I'm making a trash program similar to trash-cli.)

I tried doing make help and ./configure --help, but I found no option to simply compile one binary.

I did a trace on the Makefile, and isolated the command that produces the mv binary:
gcc -I. -I./lib -Ilib -I./lib -Isrc -I./src -g -O2 -MT src/mv.o -MD -MP -MF $depbase.Tpo -c -o src/mv.o src/mv.c &&\ echo " CCLD " src/mv;gcc -g -O2 -Wl,--as-needed -o src/mv src/mv.o src/remove.o src/copy.o src/cp-hash.o src/extent-scan.o src/force-link.o src/selinux.o src/libver.a lib/libcoreutils.a lib/libcoreutils.a -lacl -lattr

Of course, it doesn't work without all the object files already generated. I can't tell which lines are producing them, and after skimming the Makefile and configure.ac, I've concluded that I have a newfound appreciation for docker build environments. (I'm mostly a Python programmer, and don't have too much experience with the in-depth GNU toolchains.)

Unfortunately, I can't figure out how to compile it without, y'know, compiling everything else. I don't want to have to drag 50M of source code around just for a variation on a coreutils binary. How can I compile just `mv.c?

Some problems of tests

Hello,
I'm sorry to disturb you. But I have searched for a long time and have no idea.
Things are like this:
I have configured and installed coreutils:

./configure CC=x86_64-gentoo-linux-musl-gcc CFLAGS=-static --program-suffix=.x86 --prefix=coreutils-8.32/bin`
make
make install

I can find programs in the file of coreutils-8.32/bin/bin.
i have do some changes in this programs and put them in the file of coreutils-8.32/bin/after.
Now i want to compare the performance between the programs in coreutils-8.32/bin/bin and coreutils-8.32/after.
But this can't achieve by using
time make -j $(nproc) check SUBDIRS=.
What should i do?
In addition,i want to compare the performance between the single program before and after changes.
so i try to use
make check TESTS=tests/ls/ VERBOSE=yes SUBDIRS=.
to test all files in tests/ls,but failed. Could you tell a path to do that?

Thanks!

cp does not overwrite files when copying between drives

Info:

Kernel: 5.19.14-201.fsync.fc36.x86_64
Program: cp (GNU coreutils) 9.0

Description:

I have a folder with text files on an NVMe-drive that is GPT partitioned and one partition is mounted on /mnt. I try to copy this folder recursively to my SSD-drive that is running my OS. The destination folder is a older copy of the same source folder but upon using cp the present text files do not get overwritten.

Steps to Reproduce:

Destination:

cat /etc/nixos/flake.nix 
{
  description = "Makes hardware-configuration.nix available as a flake";

  outputs = { }:
    {
      nixosModules = rec {
        hwconfig = import ./hardware-configurations.nix;
        default = hwconfig;
      };
    };
}

Source:

cat /mnt/etc/nixos/flake.nix 
{
  description = "Makes hardware-configuration.nix available as a flake";

  outputs = { self, ... }:
    {
      nixosModules = rec {
        hwconfig = import ./hardware-configurations.nix;
        default = hwconfig;
      };
    };
}

Commands tried but failed (no effect):

sudo  cp /mnt/etc/nixos/ /etc/nixos/ -ai
sudo  cp /mnt/etc/nixos/ /etc/nixos/ -a
sudo  cp /mnt/etc/nixos/ /etc/nixos/ -rf
sudo  cp /mnt/etc/nixos/ /etc/nixos/ -r
sudo  cp /mnt/etc/nixos /etc/nixos -r

A command that succeeded:
sudo cp /mnt/etc/nixos/* /etc/nixos/

Expected Behavior

The destination file should be overwritten.

Unexpected behaviour of 'realpath' for option --no-symlinks

Hi all,

for me it looks like realpath does not quite work as expected.

SymLinks are resolved, even though option --no-symlinks (-s) was given.
The attached *.sh file produces the following output:

### About...

===
realpath (GNU coreutils) 8.32
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later .
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by Padraig Brady.
===

Unexpected behavior for option
  -s, --strip, --no-symlinks   don't expand symlinks


### Prepare
...

### Show setup

PWD:
/tmp/realpath-err-demo

.:
total 4
lrwxrwxrwx 1 local-admin local-admin   11 Mär  4 18:07 linked-folder -> real-folder
drwxrwxr-x 2 local-admin local-admin 4096 Mär  4 18:07 real-folder

./real-folder:
total 0
lrwxrwxrwx 1 local-admin local-admin 9 Mär  4 18:07 linked-file -> real-file
-rw-rw-r-- 1 local-admin local-admin 0 Mär  4 18:07 real-file

### Start

PWD:
/tmp/realpath-err-demo/linked-folder

### Ok so far:

Expected real-folder, real-file
/tmp/realpath-err-demo/real-folder/real-file
/tmp/realpath-err-demo/real-folder/linked-not-existing

### Unexpected:

Expected linked-folder, linked-file
/tmp/realpath-err-demo/real-folder/linked-file
/tmp/realpath-err-demo/real-folder/linked-not-existing

grretings
Ralf

Attached *.sh script

realpath-err-demo.sh.txt

dd more drive info before copies

would be nice if we could get more detailed drive infomation and confirmations with dd command.

would be nice to see an option to bypass the are you sure you want to copy over drive /dev/sdd (specific size and maybe the lsusb string so we know if its our drive) GB

INSTALL missing

The README file mentions this in the instructions:

If this file came to you as part of a tar archive, then see the file INSTALL for compilation and installation instructions.

However, there is currently no INSTALL file present in the .tar.gz archives or in the latest git repository. In fact, INSTALL is removed from the repository because it is listed in the .gitignore file. Should the README file be updated?

Jan 2038... support not detected

Trying to cross-compile a coreutils package for RPI-3 i am facing this issue. While passing the "ac_year2038_required=no" in the configuration option build get success is that ok? any sugession.

Config error:

checking for arm-linux-gnueabihf-ar... arm-linux-gnueabihf-ar
checking for arm-linux-gnueabihf-gcc option to enable large file support... -D_FILE_OFFSET_BITS=64
checking for arm-linux-gnueabihf-gcc option to enable timestamps after Jan 2038... support not detected
configure: error: in '/home/*/Documents/build/coreutils-9.3':
configure: error: support for timestamps after Jan 2038 is required
See 'config.log' for more details

Error building core Utils 8.15

I am currently truing to build coreutils 8.15 however I am getting the following error
Screen Shot 2019-03-10 at 4 05 34 PM

When running the config I get the following
Screen Shot 2019-03-10 at 4 04 04 PM

Anyone know of any fix for this?

Can't build with LLVM 5.0

Hi @pixelb @eggert ,

i can't build coreutils 8.28 with LLVM/clang 5.0.0

In file included from lib/mbsstr.c:32:
./lib/str-kmp.h:42:30: error: use of unknown builtin '__builtin_mul_overflow_p' [-Wimplicit-function-declaration]
size_t *table = (size_t *) nmalloca (m, sizeof (size_t));
^
./lib/malloca.h:79:25: note: expanded from macro 'nmalloca'
#define nmalloca(n, s) (xalloc_oversized (n, s) ? NULL : malloca ((n) * (s)))
^
./lib/xalloc-oversized.h:46:4: note: expanded from macro 'xalloc_oversized'
__builtin_mul_overflow_p (n, s, (__xalloc_count_type) 1)
^
1 error generated.

here are the logs
http://file-store.openmandriva.org/api/v1/file_stores/e06076e9b0c5cef8f2d26b80f37d0143023523c4.log?show=true

Potential race condition

According to Execution of signals signal handler may be called whenever there's transition between kernel and user mode. fork() is a syscall, so there should be such transition when it returns here. cleanup() function is installed for the number of termination signals before fork(). So it seems like it might be possible that cleanup() is called between the moment when fork() has finished and monitored_pid is assigned. This would make cleanup() to _exit() here. Then child process would continue running as long as it wants instead of being terminated.

I wasn't able to reproduce this issue.

make check failed

Bug reports

Hello!
When I executed the make check command after compiling version 8.31, the error was as follows:

PASS: test-locale../build-aux/test-driver: line 107: 2546068 Aborted (core dumped) 
\"$@\" > $log_file 2>&1FAIL: test-localeconv

This is the log:

vim gnulib-tests/test-localeconv.log
/home/all_spack_env/spack_stage/root/spack-stage-coreutils-8.31-347sljzvpccfhksnunfikddf3ldsz2nm
/spack-src/gnulib-tests/test-localeconv.c:53: assertion 'l->frac_digits == CHAR_MAX' failed
FAIL test-localeconv (exit status: 134

My system info:

cat /etc/os-release
NAME="openEuler"
VERSION="20.03 (LTS)"
ID="openEuler"
VERSION_ID="20.03"
PRETTY_NAME="openEuler 20.03 (LTS)"
ANSI_COLOR="0;31"

uname –a
Linux localhost.localdomain 4.19.90-2003.4.0.0036.oe1.aarch64 #1 SMP Mon Mar 23 19:06:43 UTC
2020 aarch64 aarch64 aarch64 GNU/Linux

Looking forward to reply!

Sort by version idiosyncrasy

I do understand that this github mirror is not a proper place for reporting bugs but I just refuse to use email do that because such a workflow IMO is absolutely inconvenient, so I'm reporting a problem here and if coreutils developers are interested they will fix it regardless.

I have coreutils 8.32 installed (to be precise coreutils-8.32-18.fc33.x86_64)

It looks like sort by version doesn't always work correctly. Consider this listing:

libpango-1.0.so
libpango-1.0.so.0
libpango-1.0.so.0.4800.4
libpangocairo-1.0.so
libpangocairo-1.0.so.0
libpangocairo-1.0.so.0.4800.4
libpangoft2-1.0.so
libpangoft2-1.0.so.0
libpangoft2-1.0.so.0.4800.4
libpangomm-1.4.so.1
libpangomm-1.4.so.1.0.30
libpangoxft-1.0.so
libpangoxft-1.0.so.0
libpangoxft-1.0.so.0.4800.4

This is exactly what you see when you sort by name.

However when you change the sorting mode to "by version" then something weird happens:

libpangocairo-1.0.so
libpangocairo-1.0.so.0
libpangocairo-1.0.so.0.4800.4
libpangoft2-1.0.so
libpangoft2-1.0.so.0
libpangoft2-1.0.so.0.4800.4
libpangomm-1.4.so.1
libpangomm-1.4.so.1.0.30
libpangoxft-1.0.so
libpangoxft-1.0.so.0
libpangoxft-1.0.so.0.4800.4
libpango-1.0.so
libpango-1.0.so.0
libpango-1.0.so.0.4800.4

This doesn't look right and seems rather illogical. Why has "libpango-1.0.so" become the last one on the list?

Please fix.

Parsing date using the single colon numeric timezone format

Hello, I can't have the single colon separated numeric timezone %:z working! My usage is in FreeBSD 12.1-RELEASE-p2 with the following test value:
date -j -f '%a, %d %b %Y %H:%M:%S %z (%Z%:z)' 'Fri, 7 Jul 2017 18:03:11 +0800 (GMT+08:00)' '+%s'

in which i basically want to parse such a formatted date string into a unix timestamp and assign it in a bash variable.

doc: sort-version.texi build error with texinfo 4.12

	if (/bin/sh /usr/src/packages/BUILD/coreutils-8.32/build-aux/missing makeinfo --version) >/dev/null 2>&1; then \
	  for f in doc/coreutils.info doc/coreutils.info-[0-9] doc/coreutils.info-[0-9][0-9] doc/coreutils.i[0-9] doc/coreutils.i[0-9][0-9]; do \
	    if test -f $f; then mv $f $backupdir; restore=mv; else :; fi; \
	  done; \
	else :; fi && \
	cd "$am__cwd"; \
	if /bin/sh /usr/src/packages/BUILD/coreutils-8.32/build-aux/missing makeinfo --no-split  -I doc -I ./doc \
	 -o doc/coreutils.info ./doc/coreutils.texi; \
	then \
	  rc=0; \
	  CDPATH="${ZSH_VERSION+.}:" && cd .; \
	else \
	  rc=$?; \
	  CDPATH="${ZSH_VERSION+.}:" && cd . && \
	  $restore $backupdir/* `echo "./doc/coreutils.info" | sed 's|[^/]*$||'`; \
	fi; \
	rm -rf $backupdir; exit $rc
./doc//sort-version.texi:885: `Related Source code' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:820: `Other version/natural sort implementations' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:790: `Reporting bugs or incorrect results' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:721: `Comparing two strings using Debian's algorithm' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:717: `Advanced Topics' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:572: `Special handling of file extensions' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:531: `Additional hard-coded priorities in GNU coreutils' version sort' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:478: `Minus/Hyphen and Colon characters' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:470: `Differences from the official Debian Algorithm' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:438: `Version sort ignores locale' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:394: `Tilde @samp{~} character' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:365: `Punctuation Characters vs letters' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:307: `Punctuation Characters' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:254: `Version sort is not the same as numeric sort' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:153: `Version-sort ordering rules' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:138: `Implementation Details' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:121: `Correct/Incorrect ordering and Expected/Unexpected results' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:103: `Origin of version sort and differences from natural sort' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:46: `Using version sort in GNU coreutils' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:19: `Version sort overview' has no Up field (perhaps incorrect sectioning?).
./doc//sort-version.texi:885: warning: unreferenced node `Related Source code'.
./doc//sort-version.texi:531: warning: unreferenced node `Additional hard-coded priorities in GNU coreutils' version sort'.
./doc//sort-version.texi:438: warning: unreferenced node `Version sort ignores locale'.
./doc//sort-version.texi:394: warning: unreferenced node `Tilde @samp{~} character'.
./doc//sort-version.texi:365: warning: unreferenced node `Punctuation Characters vs letters'.
./doc//sort-version.texi:307: warning: unreferenced node `Punctuation Characters'.
./doc//sort-version.texi:254: warning: unreferenced node `Version sort is not the same as numeric sort'.
./doc//sort-version.texi:121: warning: unreferenced node `Correct/Incorrect ordering and Expected/Unexpected results'.
./doc//sort-version.texi:103: warning: unreferenced node `Origin of version sort and differences from natural sort'.
./doc//sort-version.texi:46: warning: unreferenced node `Using version sort in GNU coreutils'.
makeinfo: Removing output file `doc/coreutils.info' due to errors; use --force to preserve.
make[2]: *** [doc/coreutils.info] Error 1

test fiemap-2.sh or sparse-2.sh fail on BTRFS

Building latest coreutils, running sparse-2.sh test on btrfs will FAIL.
After digging on the test script, and run all the test case manually, I have found the reason.
test fails on the last part, on line 58

  51 cp --sparse=always k k2 || fail=1
  52 if test $(stat -c %b k2) -ge $(stat -c %b k); then
  53   # If not sparse, then double check by creating with dd
  54   # as we're not guaranteed that seek will create a hole.
  55   # apfs on darwin 19.2.0 for example was seen to not to create holes < 16MiB.
  56   hole_size=$(stat -c %o k2) || framework_failure_
  57   dd if=k of=k2.dd bs=$hole_size conv=sparse || framework_failure_
  58   test $(stat -c %b k2) -eq $(stat -c %b k2.dd) || fail=1
  59 fi

on ext4 file system, cp --sparse=always k k2 will create k2 smaller than k, thus skip the following tests
on btrfs file system, cp --sparse=always k k2 will create k2 the same size of k, thus triggers the following tests in the if block
on line 57, however, dd if=k of=k2.dd bs=$hole_size conv=sparse will create k2.dd smaller than k2, which is also smaller than k
however, on line 58, this test expects k2 and k2.dd are the same size.
I think on line 58, -eq should be -ge, because dd if=k of=k2.dd bs=$hole_size conv=sparse works as expected to create a file smaller than the source file.

cp and dd works differently with --sparse on ext4 and btrfs

pathchk and _POSIX_NAME_MAX

$ uname -a
Linux muke 5.18.10-200.fc36.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Jul 7 17:21:38 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
$ rpm -qf $(which pathchk)
coreutils-9.0-5.fc36.x86_64
$ getconf -a | grep _POSIX_NAME_MAX
_POSIX_NAME_MAX                    255
$ pathchk -p aaaaaaaaaaaaaaaaaaaaaaaaa
pathchk: limit 14 exceeded by length 25 of file name component ‘aaaaaaaaaaaaaaaaaaaaaaaaa’

Why pathchk works with _POSIX_NAME_MAX 14 and not with 255 ?
Exist any way how pathchk will be works with _POSIX_NAME_MAX=255 ?

Thanks !

Can print -e or -n or -E from the begining of the echo

echo "-e" or echo "-n" or echo "-E" does not print -e or -n or -E even if you put it in single quote or escape the character
the workarounf that i did it add a space into the quoutes like
echo " -e"
then it will print it
or maybe
echo " -e" |sed 's/^ //'
You will have the espected result
-e

I made a script shell that uses as parameters the -e and the -n, if you put this paraemter at the begining of the call of the progman, the -e will be deleted.
example
script.sh -e -o would get in the $ @ or $* just -o

Please do not send pull-requests or open new issues on Github.

Github is a downstream mirror and is not frequently monitored,
all development is coordinated upstream on GNU resources.

Bug reports

Before reporting a new bug, please check the following resources:

Effective bug reports

  • Include a descriptive subject line (e.g. the program with which
    you experience a problem, and what the problem is).
  • Include the version of the program (e.g. the output of PROG --version).
  • Include the operating system and the type of hardware you are using
    (e.g. the output of uname -a).
  • Include the exact command and parameters you have used.
  • Clearly explain what is the output you expected to get, and what is
    the actual result you encountered.
  • Include as much information as possible to reproduce the problem.
    If the problem happens on a very large input file, try to provide
    a minimal example (a subset of the input file) that still causes the problem.
    Do not include attachments over 40kB.
  • List policy is reply-to-all, and non-subscribers may post.
  • There may be a moderation delay for a first-time post, whether or not
    you subscribe.

Mailing List Etiquette

When sending messages to [email protected] or [email protected] :

  • Send messages as plain text.
  • Do not send messages encoded as HTML nor encoded as base64 MIME nor
    included as multiple formats.
  • Avoid sending large messages, such as log files, system call trace
    output, and other content resulting in messages over about 40 kB.
  • Avoid sending screenshots (e.g. PNG files). When reporting errors
    you encounter on the terminal, copy and paste the text to your message.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.