# Access to default values

**URL:** https://www.finalbuilder.com/forums/t/access-to-default-values/1867
**Category:** Discussion
**Created:** [September 27, 2011, 3:18am UTC](https://www.finalbuilder.com/forums/t/access-to-default-values/1867 "2011-09-27T03:18:13Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [September 27, 2011, 3:18am UTC](https://www.finalbuilder.com/forums/t/access-to-default-values/1867/1 "2011-09-27T03:18:13Z")

</div>

&nbsp;Hi all,

Quick question is there any way to get hold of the default values?

For example I would like get the default repository for mercurial as a finalbuilder variable.

Also I can't quite understand why a user needs to stipulate folder/http/https/ssh when cloning a mercurial repository?

On the command its all the same:  
hg clone

You could do away with that combo box. and not loose any funcationality, unless i'm missing something.

I'm using FinalBuidler 7.0.0.1442.

Thanks

Satpal Chander

---

<div class="post-metadata">

### Author: ![stephen.ryan](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/s/f14d63/32.png) [@stephen.ryan](https://www.finalbuilder.com/forums/u/stephen.ryan)
#### Post date: [September 28, 2011, 7:12am UTC](https://www.finalbuilder.com/forums/t/access-to-default-values/1867/2 "2011-09-28T07:12:36Z")

</div>

Hi Satpal   
  
You can obtain the default repository and the default repository type with the following piece of javascript (can be used within any action script event):   
  
[code]var mercurialOptions = GetOptionsObject("Mercurial");var repo = "";var repoType = "";if (mercurialOptions != null) { repo = mercurialOptions.Properties.PropertyAsString("DefaultRepository"); repoType = mercurialOptions.Properties.PropertyAsString("DefaultRepoType");}[/code]   
  
Hope this helps.   
  
Regards,   
Steve

&nbsp;

---

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [September 28, 2011, 9:21am UTC](https://www.finalbuilder.com/forums/t/access-to-default-values/1867/3 "2011-09-28T09:21:26Z")

</div>

Regarding the need to specify the connection type - it's needed for the remote repository because we do some connection string building and validation (eg if you are authenticating with https).   
  
For the local repository, you're correct - there's no need to specify it. The (not very good) reason it's there is so that the Choose Repositories tab can be re-used between actions, and depending on the action sometimes the source is local, sometime the target is local. I'll add cleaning that up to our fix list.   
  
Cheers,   
  
Ben

---

<div class="post-metadata">

### Author: ![deleted\_user](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/deleted_user/32/937_2.png) [@deleted\_user](https://www.finalbuilder.com/forums/u/deleted_user)
#### Post date: [September 29, 2011, 9:12am UTC](https://www.finalbuilder.com/forums/t/access-to-default-values/1867/4 "2011-09-29T09:12:00Z")

</div>

&nbsp;Thanks for your responses.

&nbsp;

Satpal
