Skip to content

Instantly share code, notes, and snippets.

@siwonpawel
Last active March 16, 2022 15:14
Show Gist options
  • Save siwonpawel/040a12f6ff7eaebfdf94bcaae101b25d to your computer and use it in GitHub Desktop.
Save siwonpawel/040a12f6ff7eaebfdf94bcaae101b25d to your computer and use it in GitHub Desktop.
Extract names of branches from Bitbucket
var elements = document.getElementsByClassName("e1b5og4v0");
var names = new Set();
for(i = 0; i < elements.length; i++) {
names.add(elements[i].getElementsByTagName("a")[0].getAttribute("href"));
}
console.log(new Array(...names).join('\n'));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment