One solution that is not so sensitive to alignment of R version and package version is to download the tarball for the package fitdistrplus from CRAN here:
https://cran.r-project.org/src/contrib/fitdistrplus_1.2-2.tar.gz
Then, to install the package from this tarball rather than the CRAN repo, you can use in Rstudio:
install.packages("fitdistrplus_1.2-2.tar.gz", repos=NULL)
This will work provided the tarball is in the same directory as the Rscript you are using to install the package.
Best regards