How to serve HTML from Stash with the correct mime-type?

Is there a mode in Stash to serve HTML files repsecting their mime-type? We used to use WebSVN, which had this feature, which meant we could save the doxygen output into source control, and then browse it from within our source control viewer.

Something like how you can append &raw to the URL...

2 answers

1 accepted

Hi Kevin,

I may have been a bit hasty. You might be interested in the following feature request, which you should cast a vote on:

https://jira.atlassian.com/browse/STASH-4099

Cheers,

Charles

Thanks for the tip

Hi Kevin,

I've got the bare essentials of a plugin if you're still interested:

https://bitbucket.org/cofarrell/stash-website-plugin

Still needs a link from Stash, at the moment you need to hard-code the URL.

Charles

Thank you! I really appreciate this, got it up and running already. Let me know if you have further updates.

Hi Kevin,

Unfortunately not. Stash uses a common Atlassian HTTP library to handle raw files, and in the case of html files we intentially set the content disposition to 'attachment' to avoid any potential XSS attacks.

It wouldn't be hard to write a simple plugin that serves up html files with the correct headers, but it's unlikely something Stash will do.

Cheers,

Charles

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Jun 12, 2018 in Bitbucket

Do you use any Atlassian products for your personal projects?

After spinning my wheels trying to get organized enough to write a book for National Novel Writing Month (NaNoWriMo) I took my affinity for Atlassian products from my work life and decided to tr...

26,945 views 26 12
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you