opened 08:56PM - 26 Jun 19 UTC
closed 09:22PM - 28 Jun 19 UTC
<!--
Please keep the below portion in your issue. Your issue will be closed if …any of the boxes is not checked. In certain (rare) cases, you may be exempted if you give a brief explanation (e.g., you are only making a suggestion for improvement). Thanks!
-->
---
By filing an issue to this repo, I promise that
- [x] I have fully read the issue guide at https://yihui.name/issue/.
- [ x I have provided the necessary information about my issue.
- If I'm asking a question, I have already asked it on Stack Overflow or RStudio Community, waited for at least 24 hours, and included a link to my question there.
- If I'm filing a bug report, I have included a minimal, self-contained, and reproducible example, and have also included `xfun::session_info('rmarkdown')`. I have upgraded all my packages to their latest versions (e.g., R, RStudio, and R packages), and also tried the development version: `remotes::install_github('rstudio/rmarkdown')`.
- If I have posted the same issue elsewhere, I have also mentioned it in this issue.
- [x] I have learned the Github Markdown syntax, and formatted my issue correctly.
I understand that my issue may be closed if I don't fulfill my promises.
---
When I run rmarkdown files (example attached) in RStudio and hit "save," the rendered `.nb.html` file contains embedded images. However when I render with `Rscript -e "rmarkdown::render('file.Rmd')"`, I get image tags but no embedded images (or images in an output folder).


**RMD File as TXT** (Otherwise I'd have to escape all the stuff)
[imagetest.txt](https://github.com/rstudio/rmarkdown/files/3331870/imagetest.txt)
````
> xfun::session_info()
R version 3.5.1 (2018-07-02)
Platform: x86_64-conda_cos6-linux-gnu (64-bit)
Running under: Ubuntu 18.10, RStudio 1.1.456
Locale:
LC_CTYPE=C.UTF-8 LC_NUMERIC=C LC_TIME=C.UTF-8 LC_COLLATE=C.UTF-8
LC_MONETARY=C.UTF-8 LC_MESSAGES=C.UTF-8 LC_PAPER=C.UTF-8 LC_NAME=C
LC_ADDRESS=C LC_TELEPHONE=C LC_MEASUREMENT=C.UTF-8 LC_IDENTIFICATION=C
Package version:
askpass_1.1 assertthat_0.2.1 backports_1.1.4 base64enc_0.1-3 callr_3.2.0
cli_1.1.0 clipr_0.6.0 clisymbols_1.2.0 compiler_3.5.1 crayon_1.3.4
curl_3.3 desc_1.2.0 devtools_2.0.2 digest_0.6.19 evaluate_0.14
fs_1.3.1 gh_1.0.1 git2r_0.25.2 glue_1.3.1 graphics_3.5.1
grDevices_3.5.1 highr_0.8 htmltools_0.3.6 httr_1.4.0 ini_0.3.1
jsonlite_1.6 knitr_1.23 magrittr_1.5 markdown_1.0 memoise_1.1.0
methods_3.5.1 mime_0.7 openssl_1.4 pkgbuild_1.0.3 pkgload_1.0.2
prettyunits_1.0.2 processx_3.3.1 ps_1.3.0 purrr_0.3.2 R6_2.4.0
rcmdcheck_1.3.3 Rcpp_1.0.1 remotes_2.0.4 rlang_0.4.0 rmarkdown_1.13
rprojroot_1.3-2 rstudioapi_0.10 sessioninfo_1.1.1 stats_3.5.1 stringi_1.4.3
stringr_1.4.0 sys_3.2 tinytex_0.13 tools_3.5.1 usethis_1.5.0
utils_3.5.1 whisker_0.3.2 withr_2.1.2 xfun_0.8 xopen_1.0.0
yaml_2.2.0
```
```
(base) balter@spectre:~$ lsb_release -a
LSB Version: core-9.20170808ubuntu1-noarch:security-9.20170808ubuntu1-noarch
Distributor ID: Ubuntu
Description: Ubuntu 18.10
Release: 18.10
Codename: cosmic
```