travis-ci / travis.rb

Travis CI Client (CLI and Ruby library)
MIT License
1.59k stars 409 forks source link

Travis CLI preserve formating .travis.yml #498

Open dschwanky opened 7 years ago

dschwanky commented 7 years ago

Using travis commands to update the .travis.yml file in my repository results in the file being reformatted to the point that it is harder for a human to read it.

For Example: Original: if [ $RUN_BUILD -eq 0 ]; then git clone git@github.com:myorg/MyRepo.git ../repoFolder; git clone git@github.com:myorg/SecondRepo.git ../secondRepoFolder;

run a travis command to add a slack integration token, or something else useful.

File re formats to:

Could you preserve existing formatting?

peternewman commented 6 years ago

I suspect this may be a no, or be hard, looking at the comment here: https://github.com/travis-ci/travis.rb/issues/218#issuecomment-51029062

Is your Original all one line, what's the actual .yml formatting? Using the Insert Code GFM may help.