]> git.pld-linux.org Git - packages/coreutils.git/blob - coreutils-getgid.patch
- rel 1
[packages/coreutils.git] / coreutils-getgid.patch
1 --- coreutils-6.10/man/Makefile.am.orig 2008-01-11 11:34:22.000000000 +0100
2 +++ coreutils-6.10/man/Makefile.am      2008-03-02 02:14:20.884410857 +0100
3 @@ -59,6 +59,7 @@
4  false.1:       $(common_dep)   $(srcdir)/false.x       ../src/false.c
5  fmt.1:         $(common_dep)   $(srcdir)/fmt.x         ../src/fmt.c
6  fold.1:                $(common_dep)   $(srcdir)/fold.x        ../src/fold.c
7 +getgid.1:      $(common_dep)   $(srcdir)/getgid.x      ../src/getgid.c
8  groups.1:      $(common_dep)   $(srcdir)/groups.x      ../src/groups.c
9  head.1:                $(common_dep)   $(srcdir)/head.x        ../src/head.c
10  hostid.1:      $(common_dep)   $(srcdir)/hostid.x      ../src/hostid.c
11 diff -Nur coreutils-4.5.3.orig/man/getgid.1 coreutils-4.5.3/man/getgid.1
12 --- coreutils-4.5.3.orig/man/getgid.1   Thu Jan  1 01:00:00 1970
13 +++ coreutils-4.5.3/man/getgid.1        Sun Oct 27 21:40:54 2002
14 @@ -0,0 +1,22 @@
15 +.TH GETGID "1" "October 2002" "getgid (coreutils) 4.5.3" "User Commands"
16 +.SH NAME
17 +getgid \- print ID of given group
18 +.SH SYNOPSIS
19 +.B getgid
20 +\fIGROUPNAME\fR
21 +.SH DESCRIPTION
22 +.PP
23 +Print group ID for GROUPNAME.
24 +.PP
25 +Without any OPTION, print usage information.
26 +.SH AUTHOR
27 +Written by Artur Frysiak.
28 +.SH "REPORTING BUGS"
29 +Report bugs to <feedback@pld.org.pl>.
30 +.SH COPYRIGHT
31 +Copyright \(co 1999 Artur Frysiak.
32 +.br
33 +This is free software; see the source for copying conditions.  There is NO
34 +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
35 +.SH "SEE ALSO"
36 +.BR id (1)
37 diff -Nur coreutils-4.5.3.orig/man/pl/getgid.1 coreutils-4.5.3/man/pl/getgid.1
38 --- coreutils-4.5.3.orig/man/pl/getgid.1        Thu Jan  1 01:00:00 1970
39 +++ coreutils-4.5.3/man/pl/getgid.1     Sun Oct 27 21:46:48 2002
40 @@ -0,0 +1,22 @@
41 +.TH GETGID "1" "Pa¼dziernik 2002" "getgid (coreutils) 4.5.3" "Polecenia u¿ytkownika"
42 +.SH NAZWA
43 +getgid \- wypisuje identyfikator podanej grupy
44 +.SH SK£ADNIA
45 +.B getgid
46 +\fINAZWA-GRUPY\fR
47 +.SH OPIS
48 +.PP
49 +Wypisuje identyfikator grupy NAZWA-GRUPY.
50 +.PP
51 +Bez ¿adnych opcji podaje sposób u¿ycia.
52 +.SH AUTOR
53 +Napisane przez Artura Frysiaka.
54 +.SH "ZG£ASZANIE B£ÊDÓW"
55 +B³êdy proszê zg³aszaæ (w jêz. polskim lub angielskim) pod <feedback@pld.org.pl>.
56 +.SH COPYRIGHT
57 +Copyright \(co 1999 Artur Frysiak.
58 +.br
59 +This is free software; see the source for copying conditions.  There is NO
60 +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
61 +.SH ZOBACZ TAK¯E
62 +.BR id (1)
63 --- coreutils-6.10/src/Makefile.am.orig 2008-03-02 02:12:29.418058752 +0100
64 +++ coreutils-6.10/src/Makefile.am      2008-03-02 02:14:46.205853844 +0100
65 @@ -36,7 +36,7 @@
66    cat cksum comm csplit cut expand fmt fold head join md5sum \
67    nl od paste pr ptx sha1sum sha224sum sha256sum sha384sum sha512sum \
68    shuf sort split sum tac tail tr tsort unexpand uniq wc \
69 -  basename date dirname echo env expr factor false \
70 +  basename date dirname echo env expr factor false getgid \
71    id kill logname pathchk printenv printf pwd \
72    runcon seq sleep tee \
73    test true tty whoami yes \
74 diff -Nur coreutils-4.5.3.orig/src/getgid.c coreutils-4.5.3/src/getgid.c
75 --- coreutils-4.5.3.orig/src/getgid.c   Thu Jan  1 01:00:00 1970
76 +++ coreutils-4.5.3/src/getgid.c        Sun Oct 27 21:52:01 2002
77 @@ -0,0 +1,46 @@
78 +/* getgid - print GID of given group
79 +   Copyright (C) 1999 Artur Frysiak <wiget@pld.org.pl>
80 +
81 +   This program is free software; you can redistribute it and/or modify
82 +   it under the terms of the GNU General Public License as published by
83 +   the Free Software Foundation; either version 2, or (at your option)
84 +   any later version.
85 +
86 +   This program is distributed in the hope that it will be useful,
87 +   but WITHOUT ANY WARRANTY; without even the implied warranty of
88 +   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
89 +   GNU General Public License for more details.
90 +
91 +   You should have received a copy of the GNU General Public License
92 +   along with this program; if not, write to the Free Software Foundation,
93 +   Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
94 +
95 +#include <config.h>
96 +#include <grp.h>
97 +#include <sys/types.h>
98 +#include "system.h"
99 +
100 +int main(int argc, char **argv)
101 +{
102 +       struct group    *gr;
103 +       int             retval;
104 +
105 +       setlocale (LC_ALL, "");
106 +       bindtextdomain (PACKAGE, LOCALEDIR);
107 +       textdomain (PACKAGE);
108 +
109 +       if (argc > 1) {
110 +               gr = getgrnam(argv[1]);
111 +               if (gr) {
112 +                       printf("%d\n",gr->gr_gid);
113 +                       retval = 0;
114 +               } else {
115 +                       retval = 1;
116 +               }
117 +       } else {
118 +               printf(_("Usage:\n\t%s groupname\n"),argv[0]);
119 +               retval = 1;
120 +       }
121 +       return retval;
122 +}
123 +
124 --- coreutils-4.5.3/po/POTFILES.in.orig Mon Jul  1 23:26:55 2002
125 +++ coreutils-4.5.3/po/POTFILES.in      Fri Nov  1 02:25:41 2002
126 @@ -61,6 +61,7 @@
127  src/false.c
128  src/fmt.c
129  src/fold.c
130 +src/getgid.c
131  src/group-list.c
132  src/groups.c
133  src/head.c
134 --- coreutils-6.10/po/pl.po.orig        2008-03-02 02:12:29.526064907 +0100
135 +++ coreutils-6.10/po/pl.po     2008-03-02 02:15:20.139787629 +0100
136 @@ -3885,6 +3885,15 @@
137  msgid "invalid number of columns: %s"
138  msgstr "b³êdna liczba kolumn: %s"
139  
140 +#: src/getgid.c:37
141 +#, c-format
142 +msgid ""
143 +"Usage:\n"
144 +"\t%s groupname\n"
145 +msgstr ""
146 +"Sk³adnia:\n"
147 +"\t%s nazwa-grupy\n"
148 +
149  #: src/group-list.c:68 src/id.c:313 src/setuidgid.c:186
150  #, c-format
151  msgid "failed to get groups for user %s"
This page took 0.053957 seconds and 3 git commands to generate.