I have one javascript file in my bit bucket repo. I want to update only one line in js file during bamboo build.
Example :
version.js
myVersion="alt-1"
.......
.......
During the bamboo build, I want to change the value of myVersion variable .
Hi @Prahaladsinh Rathod ,
You can use sed.
For example in a script:
sed -i 's|myVersion="alt-1"|myVersion="alt-2"|' version.js
and use variables instead of the hardcoded values of alt-1 and alt-2.
Thanks for the reply.
But I have to commit in bitbucket repository using git command.
In my bitbucket repository, the version.js file is already there. I just want to update one line during the bamboo build process
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Are you looking to make the edit before pushing to Bitbucket or when the repository is checked out?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, I want to edit before the source code checkout
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.