5

I know how to add an image file in question post like this, but I need to add a very wide txt file and I am strugling for this.

Please, what I'm missing ?

If I click on image insertion button I can insert only image, but for the .txt?

1

1 Answer 1

5

You cannot attach a file, like you would in email. That isn’t supported. You have a few options:

Note: I would encourage anyone that thinks they need a file so big it won't fit in a code block to consider (1) if the question would be useful to others and (2) if that specific data is needed. For example, if it is just "How can I read a 12GB CSV file?", the specific contents of your CSV file is irrelevant. If the file contents really is important to the question, consider archiving the pastebin (or direct download, if one) with the Wayback Machine in case the original page goes away

But do consider this first: do you really need to include the entire file? Would your question be fine without it? If it isn't needed, don’t add it. Also, depending on the question, adding a portion of the file could work.

11
  • Great answer (as always)! The extra problem with Pastebins is that there is no guarantee that the information will remain for any particular time period. This means a dead link eventually and a loss of useful information from question,answer or comment. On the Ubuntu pastebin page I see: 'Submitted data is not guaranteed to be permanent, and may be removed at any time.' I am not sure if this is different in other pastebin services...
    – andrew.46 Mod
    Aug 17, 2022 at 4:26
  • @andrew.46 I fully agree. The Wayback Machine could work for making them permanent, but... after thinking about it more, I'm not sure using pastebins is a good idea, even if they were permanent. IMO, questions should be fully self-standing, much like MCVEs from SO. Code blocks are fine for including text files, and if content is so big a code block won't work then the question should probably made more general. IMO, if a question really needs a specific big file, then it is most likely to not be useful to anyone but the OP.
    – cocomac
    Aug 17, 2022 at 4:41
  • I have bookmarked that 'Minimal, Reproducible Example ' in my 'Moderation' bookmarks, very useful!
    – andrew.46 Mod
    Aug 17, 2022 at 4:52
  • @andrew.46 I know this would be a separate Meta post, but do you know if anyone has considered adding some portion of that page (a tl;dr probably) to our "How do I ask a good question?" page? We have a "Make it relevant to others" section, but it just says to, it doesn't explain how to
    – cocomac
    Aug 17, 2022 at 4:57
  • Hmmm... that whole AU page is a little soft on details isn't it :). I will give my colleagues a poke and get their input here...
    – andrew.46 Mod
    Aug 17, 2022 at 5:05
  • @andrew.46 Do you mind if I made a Meta post about it? I have a few additional thoughts about it, but a separate post is probably easier than comments. Of course, I don't mind if you want to poke anyone, more input is better!
    – cocomac
    Aug 17, 2022 at 5:08
  • Go for it! Always good to see some action on Meta
    – andrew.46 Mod
    Aug 17, 2022 at 5:11
  • Another issue with paste.ubuntu.com is that it seems to require an annoying login process these days. Have resorted to using Debian's pastebin...
    – Zanna Mod
    Aug 17, 2022 at 5:12
  • Would be great to improve the Help Center page, but I must point out that it is rarely OP's fault that the output they want to include is too long, as most often it's the output from the wireless info script or boot-repair report (often requested by our community members). I have done all sorts of dodgy things to shorten the output of these to fit the character limit. I wonder if we could have a bigger character limit!
    – Zanna Mod
    Aug 17, 2022 at 5:17
  • @Zanna I didn't consider that, but that makes sense. I guess you could make a Meta post for that, but is that something SE allows individual sites to change? Or is it one size limit across SE?
    – cocomac
    Aug 17, 2022 at 5:19
  • I don't know, I should think more and ask a CM!
    – Zanna Mod
    Aug 17, 2022 at 5:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .