Skip to content

Commit

Permalink
DOCS: LOC Link errors (#2188)
Browse files Browse the repository at this point in the history
  • Loading branch information
systemcrash committed Mar 17, 2023
1 parent 2960f0b commit feecdd7
Show file tree
Hide file tree
Showing 7 changed files with 169 additions and 129 deletions.
83 changes: 52 additions & 31 deletions commands/types/dnscontrol.d.ts
Expand Up @@ -725,10 +725,10 @@ declare function INCLUDE(domain: string): DomainModifier;
* One must supply the `LOC()` js helper all parameters. If that seems like too
* much work, see also helper functions:
*
* * [`LOC_BUILDER_DD()`](../record/LOC_BUILDER_DD.md) - build a `LOC` by supplying only **d**ecimal **d**egrees.
* * [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()
* * [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - build a `LOC` by supplying only **d**ecimal **d**egrees.
* * [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works
*
* ## Format ##
*
Expand Down Expand Up @@ -2198,7 +2198,13 @@ declare function CAA_BUILDER(opts: { label?: string; iodef: string; iodef_critic
declare function DMARC_BUILDER(opts: { label?: string; version?: string; policy: 'none' | 'quarantine' | 'reject'; subdomainPolicy?: 'none' | 'quarantine' | 'reject'; alignmentSPF?: 'strict' | 's' | 'relaxed' | 'r'; alignmentDKIM?: 'strict' | 's' | 'relaxed' | 'r'; percent?: number; rua?: string[]; ruf?: string[]; failureOptions?: { SPF: boolean, DKIM: boolean } | string; failureFormat?: string; reportInterval?: Duration; ttl?: Duration }): RecordModifier;

/**
* `LOC_BUILDER_DD({})` actually takes an object with the mentioned properties.
* `LOC_BUILDER_DD({})` actually takes an object with the following properties:
*
* - label (optional, defaults to `@`)
* - x
* - y
* - alt
* - ttl (optional)
*
* A helper to build [`LOC`](../domain/LOC.md) records. Supply four parameters instead of 12.
*
Expand Down Expand Up @@ -2240,18 +2246,23 @@ declare function DMARC_BUILDER(opts: { label?: string; version?: string; policy:
* ```
*
* Part of the series:
* * [`LOC()`](LOC.md) - build a `LOC` by supplying all 12 parameters
* * [`LOC()`](../domain/LOC.md) - build a `LOC` by supplying all 12 parameters
* * [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - accepts cartesian x, y
* * [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()
* * [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works
*
* @see https://dnscontrol.org/js#LOC_BUILDER_DD
*/
declare function LOC_BUILDER_DD(subdomain: string, decimal_degrees_x: float32, decimal_degrees_y: float32, altitude: float32, ttl: int): RecordModifier;
declare function LOC_BUILDER_DD(label: string, x: float32, y: float32, alt: float32, ttl: int): RecordModifier;

/**
* `LOC_BUILDER_DMM({})` actually takes an object with the mentioned properties.
* `LOC_BUILDER_DMM({})` actually takes an object with the following properties:
*
* - label (optional, defaults to `@`)
* - str
* - alt
* - ttl (optional)
*
* A helper to build [`LOC`](../domain/LOC.md) records. Supply three parameters instead of 12.
*
Expand All @@ -2277,18 +2288,23 @@ declare function LOC_BUILDER_DD(subdomain: string, decimal_degrees_x: float32, d
* ```
*
* Part of the series:
* * [`LOC()`](LOC.md) - build a `LOC` by supplying all 12 parameters
* * [`LOC()`](../domain/LOC.md) - build a `LOC` by supplying all 12 parameters
* * [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - accepts cartesian x, y
* * [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()
* * [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works
*
* @see https://dnscontrol.org/js#LOC_BUILDER_DMM
* @see https://dnscontrol.org/js#LOC_BUILDER_DMM_STR
*/
declare function LOC_BUILDER_DMM(subdomain: string, input_string: string, altitude: float32, ttl: int): RecordModifier;
declare function LOC_BUILDER_DMM_STR(label: string, str: string, alt: float32, ttl: int): RecordModifier;

/**
* `LOC_BUILDER_DMS_STR({})` actually takes an object with the mentioned properties.
* `LOC_BUILDER_DMS_STR({})` actually takes an object with the following properties:
*
* - label (optional, defaults to `@`)
* - str
* - alt
* - ttl (optional)
*
* A helper to build [`LOC`](../domain/LOC.md) records. Supply three parameters instead of 12.
*
Expand All @@ -2315,26 +2331,31 @@ declare function LOC_BUILDER_DMM(subdomain: string, input_string: string, altitu
* ```
*
* Part of the series:
* * [`LOC()`](LOC.md) - build a `LOC` by supplying all 12 parameters
* * [`LOC()`](../domain/LOC.md) - build a `LOC` by supplying all 12 parameters
* * [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - accepts cartesian x, y
* * [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()
* * [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works
*
* @see https://dnscontrol.org/js#LOC_BUILDER_DMS_STR
*/
declare function LOC_BUILDER_DMS_STR(subdomain: string, input_string: string, altitude: float32, ttl: int): RecordModifier;
declare function LOC_BUILDER_DMS_STR(label: string, str: string, alt: float32, ttl: int): RecordModifier;

/**
* `LOC_BUILDER_STR({})` actually takes an object with the mentioned properties.
* `LOC_BUILDER_STR({})` actually takes an object with the following: properties.
*
* - label (optional, defaults to `@`)
* - str
* - alt
* - ttl (optional)
*
* A helper to build [`LOC`](../domain/LOC.md) records. Supply three parameters instead of 12.
*
* Internally assumes some defaults for [`LOC`](../domain/LOC.md) records.
*
* Accepts a string and tries all `LOC_BUILDER_DM*_STR({})` methods:
* * [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
*
* ```javascript
* D("example.com","none"
Expand All @@ -2358,15 +2379,15 @@ declare function LOC_BUILDER_DMS_STR(subdomain: string, input_string: string, al
* ```
*
* Part of the series:
* * [`LOC()`](LOC.md) - build a `LOC` by supplying all 12 parameters
* * [`LOC()`](../domain/LOC.md) - build a `LOC` by supplying all 12 parameters
* * [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - accepts cartesian x, y
* * [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()
* * [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* * [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* * [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works
*
* @see https://dnscontrol.org/js#LOC_BUILDER_STR
*/
declare function LOC_BUILDER_STR(subdomain: string, input_string: string, altitude: float32, ttl: int): RecordModifier;
declare function LOC_BUILDER_STR(label: string, str: string, alt: float32, ttl: int): RecordModifier;

/**
* R53_ZONE lets you specify the AWS Zone ID for an entire domain (D()) or a specific R53_ALIAS() record.
Expand Down
9 changes: 4 additions & 5 deletions documentation/functions/domain/LOC.md
Expand Up @@ -68,11 +68,10 @@ the LOC record type will supply defaults where values were absent on DNS import.
One must supply the `LOC()` js helper all parameters. If that seems like too
much work, see also helper functions:

* [`LOC_BUILDER_DD()`](../record/LOC_BUILDER_DD.md) - build a `LOC` by supplying only **d**ecimal **d**egrees.
* [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()

* [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - build a `LOC` by supplying only **d**ecimal **d**egrees.
* [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works

## Format ##

Expand Down
32 changes: 19 additions & 13 deletions documentation/functions/record/LOC_BUILDER_DD.md
@@ -1,20 +1,26 @@
---
name: LOC_BUILDER_DD
parameters:
- subdomain
- decimal_degrees_x
- decimal_degrees_y
- altitude
- label
- x
- y
- alt
- ttl
parameter_types:
subdomain: string
decimal_degrees_x: float32
decimal_degrees_y: float32
altitude: float32
label: string
x: float32
y: float32
alt: float32
ttl: int
---

`LOC_BUILDER_DD({})` actually takes an object with the mentioned properties.
`LOC_BUILDER_DD({})` actually takes an object with the following properties:

- label (optional, defaults to `@`)
- x
- y
- alt
- ttl (optional)

A helper to build [`LOC`](../domain/LOC.md) records. Supply four parameters instead of 12.

Expand Down Expand Up @@ -61,8 +67,8 @@ D("example.com","none"


Part of the series:
* [`LOC()`](LOC.md) - build a `LOC` by supplying all 12 parameters
* [`LOC()`](../domain/LOC.md) - build a `LOC` by supplying all 12 parameters
* [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - accepts cartesian x, y
* [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()
* [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works
29 changes: 17 additions & 12 deletions documentation/functions/record/LOC_BUILDER_DMM_STR.md
@@ -1,18 +1,23 @@
---
name: LOC_BUILDER_DMM
name: LOC_BUILDER_DMM_STR
parameters:
- subdomain
- input_string
- altitude
- label
- str
- alt
- ttl
parameter_types:
subdomain: string
input_string: string
altitude: float32
label: string
str: string
alt: float32
ttl: int
---

`LOC_BUILDER_DMM({})` actually takes an object with the mentioned properties.
`LOC_BUILDER_DMM({})` actually takes an object with the following properties:

- label (optional, defaults to `@`)
- str
- alt
- ttl (optional)

A helper to build [`LOC`](../domain/LOC.md) records. Supply three parameters instead of 12.

Expand Down Expand Up @@ -42,8 +47,8 @@ D("example.com","none"


Part of the series:
* [`LOC()`](LOC.md) - build a `LOC` by supplying all 12 parameters
* [`LOC()`](../domain/LOC.md) - build a `LOC` by supplying all 12 parameters
* [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - accepts cartesian x, y
* [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()
* [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works
27 changes: 16 additions & 11 deletions documentation/functions/record/LOC_BUILDER_DMS_STR.md
@@ -1,18 +1,23 @@
---
name: LOC_BUILDER_DMS_STR
parameters:
- subdomain
- input_string
- altitude
- label
- str
- alt
- ttl
parameter_types:
subdomain: string
input_string: string
altitude: float32
label: string
str: string
alt: float32
ttl: int
---

`LOC_BUILDER_DMS_STR({})` actually takes an object with the mentioned properties.
`LOC_BUILDER_DMS_STR({})` actually takes an object with the following properties:

- label (optional, defaults to `@`)
- str
- alt
- ttl (optional)

A helper to build [`LOC`](../domain/LOC.md) records. Supply three parameters instead of 12.

Expand Down Expand Up @@ -43,8 +48,8 @@ D("example.com","none"


Part of the series:
* [`LOC()`](LOC.md) - build a `LOC` by supplying all 12 parameters
* [`LOC()`](../domain/LOC.md) - build a `LOC` by supplying all 12 parameters
* [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - accepts cartesian x, y
* [`LOC_BUILDER_DMS_STR({})`](LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](LOC_BUILDER_STR.md) - tries LOC_BUILDER_DM*STR()
* [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works
61 changes: 61 additions & 0 deletions documentation/functions/record/LOC_BUILDER_STR.md
@@ -0,0 +1,61 @@
---
name: LOC_BUILDER_STR
parameters:
- label
- str
- alt
- ttl
parameter_types:
label: string
str: string
alt: float32
ttl: int
---

`LOC_BUILDER_STR({})` actually takes an object with the following: properties.

- label (optional, defaults to `@`)
- str
- alt
- ttl (optional)

A helper to build [`LOC`](../domain/LOC.md) records. Supply three parameters instead of 12.

Internally assumes some defaults for [`LOC`](../domain/LOC.md) records.


Accepts a string and tries all `LOC_BUILDER_DM*_STR({})` methods:
* [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E


{% code title="dnsconfig.js" %}
```javascript
D("example.com","none"
, LOC_BUILDER_STR({
label: "old-faithful",
str: '44.46046°N 110.82815°W',
alt: 2240,
})
, LOC_BUILDER_STR({
label: "ribblehead-viaduct",
str: '54.210436°N 2.370231°W',
alt: 300,
})
, LOC_BUILDER_STR({
label: "guinness-brewery",
str: '53°20′40″N 6°17′20″W',
alt: 300,
})
);

```
{% endcode %}


Part of the series:
* [`LOC()`](../domain/LOC.md) - build a `LOC` by supplying all 12 parameters
* [`LOC_BUILDER_DD({})`](../record/LOC_BUILDER_DD.md) - accepts cartesian x, y
* [`LOC_BUILDER_DMS_STR({})`](../record/LOC_BUILDER_DMS_STR.md) - accepts DMS 33°51′31″S 151°12′51″E
* [`LOC_BUILDER_DMM_STR({})`](../record/LOC_BUILDER_DMM_STR.md) - accepts DMM 25.24°S 153.15°E
* [`LOC_BUILDER_STR({})`](../record/LOC_BUILDER_STR.md) - tries the cooordinate string in all `LOC_BUILDER_DM*_STR()` functions until one works

0 comments on commit feecdd7

Please sign in to comment.