Skip to content

Commit 1d2c14b

Browse files
authored
use cat instead of echo for heredocs (#102)
1 parent 8737110 commit 1d2c14b

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

inst/scripts/add_cranapt_noble.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ apt update -qq && apt install --yes --no-install-recommends ca-certificates gnup
1818
gpg --homedir /tmp --no-default-keyring --keyring /usr/share/keyrings/r2u.gpg --keyserver keyserver.ubuntu.com --recv-keys A1489FE2AB99A21A 67C2D66C4B1D4339 51716619E084DAB9
1919

2020
## Second: add the repo -- here we use the well-connected mirror
21-
echo > /etc/apt/sources.list.d/r2u.sources <<EOF
21+
cat > /etc/apt/sources.list.d/r2u.sources <<EOF
2222
Types: deb
2323
URIs: https://r2u.stat.illinois.edu/ubuntu
2424
Suites: noble
@@ -28,7 +28,7 @@ Signed-By: /usr/share/keyrings/r2u.gpg
2828
EOF
2929

3030
## Third: ensure current R is used
31-
echo > /etc/apt/sources.list.d/cran.sources <<EOF
31+
cat > /etc/apt/sources.list.d/cran.sources <<EOF
3232
Types: deb
3333
URIs: https://cloud.r-project.org/bin/linux/ubuntu
3434
Suites: noble-cran40/
@@ -40,7 +40,7 @@ apt update -qq
4040
DEBIAN_FRONTEND=noninteractive apt install --yes --no-install-recommends r-base-core
4141

4242
## Fourth: add pinning to ensure package sorting
43-
echo > /etc/apt/preferences.d/99cranapt <<EOF
43+
cat > /etc/apt/preferences.d/99cranapt <<EOF
4444
Package: *
4545
Pin: release o=CRAN-Apt Project
4646
Pin: release l=CRAN-Apt Packages
@@ -52,7 +52,7 @@ EOF
5252
apt install --yes --no-install-recommends python3-{dbus,gi,apt} make
5353
## Then install bspm (as root) and enable it, and enable a speed optimization
5454
Rscript -e 'install.packages("bspm")'
55-
echo >> /etc/R/Rprofile.site <<EOF
55+
cat >> /etc/R/Rprofile.site <<EOF
5656
suppressMessages(bspm::enable())
5757
options(bspm.version.check=FALSE)
5858
EOF

0 commit comments

Comments
 (0)