Ajutor script shell
Andrei POPESCU <[email protected]> Sun, 6 Jan 2019 14:43:17 +0200
| Newsgroups | gmane.org.user-groups.rlug.general |
|---|---|
| Message-ID | <20190106124317.ytdewmluc4sgmwtk@pine64> |
--===============4244660638428908814==
Content-Type: multipart/signed; micalg=pgp-sha256;
protocol="application/pgp-signature"; boundary="g2wyb52hw3cqgenq"
Content-Disposition: inline
--g2wyb52hw3cqgenq
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Salut,
Din categoria =E2=80=9Emerge, merge, dar de ce?=E2=80=9D se d=C4=83 urm=C4=
=83toarea bucat=C4=83 de=20
script:
#!/bin/sh
USER_NAME=3Dtest
USER_FULL_NAME=3D"FNU LNU"
# useful to have files with same owner across different systems
# if unset the adduser default will be used (1000)
USER_UID=3D1666
adduser --disabled-password --gecos \""$USER_FULL_NAME"\" ${USER_UID:+\--ui=
d ${USER_UID}} "$USER_NAME"
Dup=C4=83 multe experimente am descoperit c=C4=83 trebuie s=C4=83 protejez =
prima "-"=20
din "--uid" =C8=99i s=C4=83 *nu* =C3=AEncadrez variabila =C3=AEn ghilimele =
(care =C3=AEn mod=20
normal sunt recomandate la orice variabil=C4=83), dar nu =C3=AEn=C8=9Beleg =
de ce :(
Vreau s=C4=83 m=C4=83 asigur c=C4=83 nu am introdus vreun bug cu rezultate.=
=2E.=20
=E2=80=9Einteresante=E2=80=9D =C8=99i s=C4=83 =C3=AEnv=C4=83=C8=9B ceva pe =
l=C3=A2ng=C4=83 ;)
Bonus: s=C4=83 folosesc aceia=C8=99i metod=C4=83 =C8=99i pentru $USER_FULL_=
NAME, care foarte=20
probabil va con=C8=9Bine cel pu=C8=9Bin spa=C8=9Bii, dac=C4=83 nu =C8=99i a=
lte caractere=20
speciale.
Problema urgent=C4=83 fiind rezolvat=C4=83 (cred), nu sunt interesat de sol=
u=C8=9Bii=20
rescrise dec=C3=A2t dac=C4=83 metoda folosit=C4=83 de mine e =E2=80=9Eperic=
uloas=C4=83=E2=80=9D pentru c=C4=83=20
$motiv.
Pentru c=C4=83 scriptul ar trebui s=C4=83 func=C8=9Bioneze =C8=99i pe un si=
stem foarte=20
limitat (e.g. busybox) a=C8=99 vrea s=C4=83 evit bashisme =C8=99i/sau alte =
shelluri=20
(momentan testez cu sh -> dash).
Mul=C8=9Bumesc de interes,
Andrei
--=20
If you can't explain it simply, you don't understand it well enough.
(Albert Einstein)
--g2wyb52hw3cqgenq
Content-Type: application/pgp-signature; name="signature.asc"
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCAAdFiEE5E64jOIbhY42OXqk/8eFRO8iNBwFAlwx9+QACgkQ/8eFRO8i
NByAXw//WedCQt/vDJXjBSzXlZZPxffSiZkhm7LrNdPD0Ciz7nwR/9jqzBjoVTZU
52TRvTnWE/YxcasOxCjbsvbANXBZ5/cD22ziuq9/DcYCxNrvmoxBuIVKKWKXJARz
r4AM11s+adttjbxShX1m8LE5LcGJLlHS8VNiR3oKngKcQ+FUn30HWQsMWF936wUB
BDT5kpDLEOP+QeXovpdG/rZUWSOogdIJxqAEoczE93fLpHkXBn7S0X1RwiO39nRp
3wvd/W90AzFyxKAyIun21UctGM+4B6TgYefaKeumA7OOBqJoFfzhd6Yq+c7vrEcB
QuOWd4iyfqmNTizJ+/nMY/TWiaJ3+9UwhOVuTPj5slDryG92Ah2l+d5He5oqdB/D
Nv8MBrNohQPNi/r105XOVGyWehNOVNURNnQfhR8WE+Qpv0tTho+yPWk1p9M9UFuZ
IQIrNEuy8yXOkrKQ8uEDePDrAtSSdaFnVl2tAOBcWFMYRlLMXz6XFfqyaA+zMqaB
IYhzqGYNuvSSzB9GiIA0W3gDbidUcr1A7hy96vLY3KE3VG2mMwzbN9M/WUSKurew
JgaoF4zHnZn3R359A44Qf6PKJTjrgGF//8I4lXmT47UeBinyONvsY6hxKl0fUXyx
lIghlhfAIzxx7sMq3KhJGfrxEVkNLVbkoVGIzVteNS9Aki2UKGg=
=2Sxi
-----END PGP SIGNATURE-----
--g2wyb52hw3cqgenq--
--===============4244660638428908814==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
_______________________________________________
RLUG mailing list
[email protected]
http://lists.lug.ro/mailman/listinfo/rlug_lists.lug.ro
--===============4244660638428908814==--