Command Line (batch) formatting
Chillier
Posts: 11
We would like to make a Jenkins task to format our SQL before committing. Is there a way to specify a "command line" command to format :?:
Comments
Unfortunately there's no way to get prompt to run from the command line at the moment.
Could I ask how you'd want this to work? A command line exe that'd take in a .sql file and an exported .sqlpromptstyle file that then writes out a new formatted .sql file?
Thanks,
Aaron.
Thanks, but not sure. We just want to automate the action of applying a standard formatting before committing.
When we commit, we want the diff to show our actual changes, not programmer-specific formatting changes.... so we want to automagically apply the same formatting template to all SQL code.
mvh Charles
We've had a request to automatically add prompt formatting in the commit tab on UserVoice here which sounds like it'd be exactly what you need?
I've let our SQL Source Control team know that you'd like this feature. It sounds like a really good idea, please do vote on the UserVoice request as it helps them to prioritise which features to work on next.
Thanks,
Aaron.