oficina / mapa Public

Clone
git clone https://amadan.net/oficina/mapa

Plain git — no account needed to clone.

Download

Download this file

1package main
2
3// The columns and icons spec's mutations for pages inside and the
4// import's pins (§9): a private page inside a team page, and a root
5// pinned again on every run.
6
7const (
8 insideGo = "internal/mapa/inside.go"
9 importPinsGo = "internal/mapa/import_pins.go"
10)
11
12var insideMutations = []mutation{
13 {gate: "IN3", test: "TestIN3PrivateInLinesAreNoPageInside",
14 name: "a private page's In: line counts",
15 edits: []edit{{file: insideGo,
16 from: "\tif kind != KindPage || rung != RungTeam || " +
17 "len(blocks) == 0 {",
18 to: "\tif len(blocks) == 0 {"}, {file: insideGo,
19 from: "\t\t\tif child != page.id && index.team[child] {",
20 to: "\t\t\tif child != page.id {"}}},
21 {gate: "I23", test: "TestI23TheImportPinsItsRootsOnce", pkg: inside,
22 name: "a root is offered on every run",
23 edits: []edit{{file: importPinsGo,
24 from: "\t\tif entry.place.Pin != nil || entry.place.PageID == 0 ||",
25 to: "\t\tif entry.place.PageID == 0 ||"}}},
26}
27