# Missing a write("file.txt",mynumber, "a") shortcut

**URL:** <https://discourse.julialang.org/t/missing-a-write-file-txt-mynumber-a-shortcut/142952>\
**Category:** Internals & Design\
**Created:** [November 14, 2026, 8:18pm UTC](https://discourse.julialang.org/t/missing-a-write-file-txt-mynumber-a-shortcut/142952 "2026-11-14T20:18:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Post date:** [November 14, 2026, 8:18pm UTC](https://discourse.julialang.org/t/missing-a-write-file-txt-mynumber-a-shortcut/142952/1 "2026-11-14T20:18:46Z")

</div>

I know that I can open/close a file and print on it, but sometime I find convenient to use write, especially when the time for opening/closing the stream is irrelevant.

I miss a version of `write` where I can specify to append instead of overwrite the whole file :-/

---

<div class="post-metadata">

**Author:** ![rafael.guerra](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rafael.guerra/32/216610_2.png) [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)\
**Post date:** [November 15, 2026, 12:13am UTC](https://discourse.julialang.org/t/missing-a-write-file-txt-mynumber-a-shortcut/142952/2 "2026-11-15T00:13:13Z")

</div>

It’s already rather short:

```julia-auto
open(io -> write(io, mystring), "file.txt", "a")

```
