boggo 0.0.0-stage → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,204 @@
1
+ // Komentojen (src/commands.js) tekstit suomeksi ja englanniksi. Uusi teksti molemmille kielille (testi tarkistaa avaimet).
2
+
3
+ export const CMD = {
4
+ fi: {
5
+ errorMark: "Virhe:",
6
+ warnMark: "Huom.:",
7
+ yes: "K",
8
+ yesNo: "K/e",
9
+ defaultMark: "(oletus)",
10
+ pickNumber: (n) => `Kirjoita numero 1–${n}.`,
11
+ inputEnded: "Syöte loppui. Anna valinnat komennolla (katso boggo help).",
12
+ unknown: (c) => `Tuntematon komento: ${c}. Katso boggo help.`,
13
+ noConnection: (url) => `Boggo Cloudiin (${url}) ei saatu yhteyttä. Tarkista verkkoyhteys ja yritä uudelleen.`,
14
+ timedOut: (url) => `Boggo Cloud (${url}) ei vastannut ajoissa.`,
15
+ uploadTimedOut: (url) => `Paketin lähetys kesti liian kauan. Julkaisu on voinut silti alkaa: tarkista ${url} ennen kuin yrität uudelleen.`,
16
+ needOrg: (orgs) => `Kuulut useampaan organisaatioon (${orgs.join(", ")}). Anna organisaatio: --org <slug>`,
17
+ httpFailed: (s) => `Boggo Cloud vastasi virheellä (${s}). Yritä uudelleen.`,
18
+ loginAgain: "Kirjautuminen on vanhentunut tai peruttu. Kirjaudu uudelleen: boggo login",
19
+ notLoggedIn: "Et ole kirjautunut. Kirjaudu ensin: boggo login",
20
+ notLoggedInShort: "Et ole kirjautunut tällä koneella.",
21
+ tokenFromEnv: "Tunnus tulee ympäristömuuttujasta BOGGO_TOKEN. Poista se, jos haluat kirjautua tai kirjautua ulos.",
22
+ tokenInvalid: "Ympäristömuuttujan BOGGO_TOKEN arvo ei ole kelvollinen tunnus. Korjaa arvo tai poista muuttuja, niin koneelle tallennettu kirjautuminen on käytössä.",
23
+ loginOpen: "Avaa tämä osoite selaimessa ja salli kirjautuminen:",
24
+ loginCode: (code) => `Tarkista, että selaimessa näkyy sama koodi: ${code}`,
25
+ loginWaiting: "Odotetaan hyväksyntää…",
26
+ loggedIn: (email) => `Kirjauduttu${email ? `: ${email}` : ""}.`,
27
+ nextInit: "Seuraavaksi: aja projektin kansiossa boggo init",
28
+ loginExpired: "Kirjautumista ei hyväksytty 10 minuutissa. Aja boggo login uudelleen.",
29
+ cliNotSupported: (url) => `Boggo Cloud (${url}) ei vielä tue kirjautumista komentoriviltä. Kirjautuminen onnistuu, kun komentorivityökalu on otettu käyttöön portaalissa.`,
30
+ checkPortalUrl: "Tarkista myös ympäristömuuttuja BOGGO_URL.",
31
+ badPortalUrl: (url) => `Boggo Cloudin osoite ${url} ei kelpaa: sen pitää alkaa https:// (http:// vain omalla koneella). Tarkista ympäristömuuttuja BOGGO_URL.`,
32
+ linkOtherPortal: (linked, current) => `Kansio on yhdistetty projektiin toisessa Boggo Cloudissa (${linked}), ei tässä (${current}). Yhdistä kansio uudelleen: boggo link`,
33
+ revokeFailed: "Tunnusta ei saatu mitätöityä Boggo Cloudissa. Mitätöi se tarvittaessa portaalissa: Oma tili → Kirjautumiset.",
34
+ loggedOut: "Kirjauduttu ulos tältä koneelta.",
35
+ roles: { owner: "omistaja", admin: "ylläpitäjä", developer: "kehittäjä", viewer: "katselija" },
36
+ kinds: { palvelin: "palvelin", tietokanta: "tietokanta" },
37
+ states: { valmis: "valmis", luodaan: "luodaan", virhe: "virhe" },
38
+ pickOrg: "Mihin organisaatioon?",
39
+ noProjects: "Organisaatiossa ei ole vielä projekteja. Luo ensimmäinen: boggo init",
40
+ linked: (name) => `Kansio yhdistetty projektiin ${name}.`,
41
+ gitignoreAdded: "Kansio .boggo lisättiin tiedostoon .gitignore.",
42
+ alreadyLinked: (name) => `Kansio on jo yhdistetty projektiin ${name}.`,
43
+ nextPush: "Julkaise: boggo push --prod",
44
+ noApp: "Kansiosta ei löytynyt verkkosivua eikä sovellusta (package.json, Dockerfile tai index.html). Aja komento sovelluksen kansiossa.",
45
+ found: (type) => `Löytyi: ${type}`,
46
+ newOrExisting: "Luodaanko uusi projekti vai yhdistetäänkö olemassa olevaan?",
47
+ newProject: "Uusi projekti",
48
+ existingProject: "Olemassa oleva projekti",
49
+ askName: "Projektin nimi (siitä tulee osoite <nimi>.boggo.app)",
50
+ nameTaken: (name) => `Nimi ${name} on jo käytössä.`,
51
+ suggestions: (list) => `Vapaita: ${list}.`,
52
+ askUse: "Mitä sovellus tekee?",
53
+ useSite: "Verkkosivu",
54
+ useApi: "Sovelluksen rajapinta",
55
+ badUse: "Käyttö ei kelpaa. Vaihtoehdot: verkkosivu, rajapinta.",
56
+ askSize: "Koko",
57
+ badSize: "Koko ei kelpaa. Vaihtoehdot: pieni, perus, iso.",
58
+ confirmCreate: (name, size) => `Luodaanko projekti ${name} (${size})?`,
59
+ cancelled: "Peruttu.",
60
+ creating: (name) => `Luodaan projektia ${name}…`,
61
+ created: (name, url) => `Projekti ${name} luotu: ${url}`,
62
+ projectNotDeployable: (name) => `Projektiin ${name} ei voi julkaista komentoriviltä. Luo uusi projekti: boggo init`,
63
+ noDeployable: "Organisaatiossa ei ole projektia, johon voi julkaista komentoriviltä. Luo uusi: boggo init",
64
+ needProject: "Anna projekti: --project <name>",
65
+ pickProject: "Mikä projekti?",
66
+ projectNotFound: (name) => `Projektia ${name} ei löydy. Katso projektit: boggo projects`,
67
+ notLinked: "Kansiota ei ole yhdistetty projektiin. Aja boggo init tai anna --project <name> (ja --org <slug>, jos kuulut useampaan organisaatioon).",
68
+ notLinkedInit: "Kansiota ei ole vielä yhdistetty projektiin.",
69
+ emptyFolder: "Kansiossa ei ole julkaistavia tiedostoja.",
70
+ skippedBig: (path, size) => `${path} jätettiin pois (${size}, raja 50 Mt).`,
71
+ skippedLink: (path) => `${path} jätettiin pois (linkki kansion ulkopuolelle).`,
72
+ unreadable: (list, n) =>
73
+ `Näitä ei voi lukea, joten pakettia ei lähetetty: ${list.join(", ")}${n > list.length ? ` ja ${n - list.length} muuta` : ""}. Korjaa oikeudet tai jätä ne pois tiedostolla .boggoignore.`,
74
+ tooBig: (max) => `Paketti on yli ${max}. Jätä riippuvuudet ja rakennuksen tulokset pois tiedostolla .boggoignore.`,
75
+ uploading: (n, size, project) => `Lähetetään ${n} ${n === 1 ? "tiedosto" : "tiedostoa"} (${size}) projektiin ${project}…`,
76
+ waitingCreate: "Projekti on vielä luonnissa. Odotetaan…",
77
+ uploadChecking: "Boggo Cloud tarkistaa paketin…",
78
+ deployment: (n) => `Julkaisu #${n}`,
79
+ build: (n) => `Rakennus #${n}`,
80
+ queued: (label, app) => `${label} aloitettu (${app}).`,
81
+ stages: {
82
+ jonossa: "Jonossa",
83
+ haetaan: "Puretaan paketti",
84
+ rakennetaan: "Rakennetaan",
85
+ siirretaan: "Siirretään palvelimelle",
86
+ kaynnistetaan: "Käynnistetään ja tarkistetaan",
87
+ },
88
+ stillRunning: (url) => `Julkaisu kestää yli 45 minuuttia, joten seuranta lopetettiin. Julkaisu jatkuu Boggo Cloudissa: ${url}`,
89
+ lostTrack: (url) => `Boggo Cloudiin ei saatu yhteyttä 5 minuuttiin, joten julkaisun tulosta ei tiedetä. Tarkista tila: ${url}`,
90
+ deployed: (s) => `Julkaistu (${s} s):`,
91
+ built: (s) => `Rakennus onnistui (${s} s). Mitään ei julkaistu.`,
92
+ nextProd: "Julkaise tuotantoon: boggo push --prod",
93
+ nextPromote: "Julkaise tämä rakennus tuotantoon ilman uutta rakennusta: boggo promote",
94
+ promoting: (build, deployment) => `${build} tuotantoon: ${deployment} jonossa.`,
95
+ noBuild: "Kansiossa ei ole julkaistavaa rakennusta. Rakenna ensin: boggo push (tai anna numero: boggo promote 12)",
96
+ badBuildNumber: (v) => `${v} ei ole rakennuksen numero. Esimerkki: boggo promote 12`,
97
+ varsChangedForce: "Julkaise silti valinnalla --force tai rakenna uudelleen: boggo push",
98
+ promoteAnyway: "Julkaistaanko silti?",
99
+ replaced: "Uudempi julkaisu korvasi tämän ennen kuin se alkoi.",
100
+ failed: "Julkaisu epäonnistui.",
101
+ seeLog: (url) => `Koko loki: ${url}`,
102
+ noAddress: (name) => `Projektilla ${name} ei ole julkista osoitetta.`,
103
+ },
104
+ en: {
105
+ errorMark: "Error:",
106
+ warnMark: "Note:",
107
+ yes: "Y",
108
+ yesNo: "Y/n",
109
+ defaultMark: "(default)",
110
+ pickNumber: (n) => `Type a number 1–${n}.`,
111
+ inputEnded: "Input ended. Give the choices as options (see boggo help).",
112
+ unknown: (c) => `Unknown command: ${c}. See boggo help.`,
113
+ noConnection: (url) => `Could not connect to Boggo Cloud (${url}). Check your network and try again.`,
114
+ timedOut: (url) => `Boggo Cloud (${url}) did not answer in time.`,
115
+ uploadTimedOut: (url) => `Uploading the package took too long. The deployment may have started anyway: check ${url} before you try again.`,
116
+ needOrg: (orgs) => `You belong to several organizations (${orgs.join(", ")}). Give one: --org <slug>`,
117
+ httpFailed: (s) => `Boggo Cloud responded with an error (${s}). Try again.`,
118
+ loginAgain: "Your login has expired or was revoked. Log in again: boggo login",
119
+ notLoggedIn: "You are not logged in. Log in first: boggo login",
120
+ notLoggedInShort: "You are not logged in on this machine.",
121
+ tokenFromEnv: "The token comes from the environment variable BOGGO_TOKEN. Remove it to log in or out.",
122
+ tokenInvalid: "The environment variable BOGGO_TOKEN is not a valid token. Fix the value or remove the variable to use the login saved on this machine.",
123
+ loginOpen: "Open this address in your browser and allow the login:",
124
+ loginCode: (code) => `Check that the browser shows the same code: ${code}`,
125
+ loginWaiting: "Waiting for approval…",
126
+ loggedIn: (email) => `Logged in${email ? `: ${email}` : ""}.`,
127
+ nextInit: "Next: run boggo init in your project folder",
128
+ loginExpired: "The login was not approved within 10 minutes. Run boggo login again.",
129
+ cliNotSupported: (url) => `Boggo Cloud (${url}) doesn't support logging in from the command line yet. You can log in once the command-line tool is enabled in the portal.`,
130
+ checkPortalUrl: "Also check the environment variable BOGGO_URL.",
131
+ badPortalUrl: (url) => `The Boggo Cloud address ${url} is not valid: it must start with https:// (http:// only on your own machine). Check the environment variable BOGGO_URL.`,
132
+ linkOtherPortal: (linked, current) => `This folder is linked to a project in another Boggo Cloud (${linked}), not this one (${current}). Link the folder again: boggo link`,
133
+ revokeFailed: "The token could not be revoked in Boggo Cloud. If needed, revoke it in the portal: Account → Logins.",
134
+ loggedOut: "Logged out on this machine.",
135
+ roles: { owner: "owner", admin: "admin", developer: "developer", viewer: "viewer" },
136
+ kinds: { palvelin: "server", tietokanta: "database" },
137
+ states: { valmis: "ready", luodaan: "creating", virhe: "error" },
138
+ pickOrg: "Which organization?",
139
+ noProjects: "The organization has no projects yet. Create the first one: boggo init",
140
+ linked: (name) => `Folder linked to project ${name}.`,
141
+ gitignoreAdded: "Added the folder .boggo to .gitignore.",
142
+ alreadyLinked: (name) => `This folder is already linked to project ${name}.`,
143
+ nextPush: "Deploy: boggo push --prod",
144
+ noApp: "No website or app found in this folder (package.json, Dockerfile or index.html). Run the command in your app's folder.",
145
+ found: (type) => `Found: ${type}`,
146
+ newOrExisting: "Create a new project or link an existing one?",
147
+ newProject: "New project",
148
+ existingProject: "Existing project",
149
+ askName: "Project name (becomes the address <name>.boggo.app)",
150
+ nameTaken: (name) => `The name ${name} is taken.`,
151
+ suggestions: (list) => `Available: ${list}.`,
152
+ askUse: "What does the app do?",
153
+ useSite: "Website",
154
+ useApi: "App API",
155
+ badUse: "Invalid use. Choices: site, api.",
156
+ askSize: "Size",
157
+ badSize: "Invalid size. Choices: small, basic, large.",
158
+ confirmCreate: (name, size) => `Create project ${name} (${size})?`,
159
+ cancelled: "Cancelled.",
160
+ creating: (name) => `Creating project ${name}…`,
161
+ created: (name, url) => `Project ${name} created: ${url}`,
162
+ projectNotDeployable: (name) => `Project ${name} can't be deployed from the command line. Create a new project: boggo init`,
163
+ noDeployable: "The organization has no project you can deploy from the command line. Create one: boggo init",
164
+ needProject: "Give a project: --project <name>",
165
+ pickProject: "Which project?",
166
+ projectNotFound: (name) => `Project ${name} not found. See your projects: boggo projects`,
167
+ notLinked: "This folder is not linked to a project. Run boggo init or give --project <name> (and --org <slug> if you belong to several organizations).",
168
+ notLinkedInit: "This folder is not linked to a project yet.",
169
+ emptyFolder: "There are no files to deploy in this folder.",
170
+ skippedBig: (path, size) => `Left out ${path} (${size}, limit 50 MB).`,
171
+ skippedLink: (path) => `Left out ${path} (link outside the folder).`,
172
+ unreadable: (list, n) =>
173
+ `These can't be read, so nothing was uploaded: ${list.join(", ")}${n > list.length ? ` and ${n - list.length} more` : ""}. Fix the permissions or leave them out with a .boggoignore file.`,
174
+ tooBig: (max) => `The package is over ${max}. Leave out dependencies and build output with a .boggoignore file.`,
175
+ uploading: (n, size, project) => `Uploading ${n} ${n === 1 ? "file" : "files"} (${size}) to project ${project}…`,
176
+ waitingCreate: "The project is still being created. Waiting…",
177
+ uploadChecking: "Boggo Cloud is checking the package…",
178
+ deployment: (n) => `Deployment #${n}`,
179
+ build: (n) => `Build #${n}`,
180
+ queued: (label, app) => `${label} started (${app}).`,
181
+ stages: {
182
+ jonossa: "Queued",
183
+ haetaan: "Unpacking",
184
+ rakennetaan: "Building",
185
+ siirretaan: "Moving to the server",
186
+ kaynnistetaan: "Starting and checking",
187
+ },
188
+ stillRunning: (url) => `The deployment has taken over 45 minutes, so following stopped. It continues in Boggo Cloud: ${url}`,
189
+ lostTrack: (url) => `Could not reach Boggo Cloud for 5 minutes, so the result of the deployment is unknown. Check its status: ${url}`,
190
+ deployed: (s) => `Deployed (${s} s):`,
191
+ built: (s) => `Build succeeded (${s} s). Nothing was deployed.`,
192
+ nextProd: "Deploy to production: boggo push --prod",
193
+ nextPromote: "Deploy this build to production without building again: boggo promote",
194
+ promoting: (build, deployment) => `${build} to production: ${deployment} queued.`,
195
+ noBuild: "This folder has no build to deploy. Build first: boggo push (or give a number: boggo promote 12)",
196
+ badBuildNumber: (v) => `${v} is not a build number. Example: boggo promote 12`,
197
+ varsChangedForce: "Deploy anyway with --force, or build again: boggo push",
198
+ promoteAnyway: "Deploy anyway?",
199
+ replaced: "A newer deployment replaced this one before it started.",
200
+ failed: "The deployment failed.",
201
+ seeLog: (url) => `Full log: ${url}`,
202
+ noAddress: (name) => `Project ${name} has no public address.`,
203
+ },
204
+ };