@devtion/devcli 1.0.5-alpha.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.
Files changed (42) hide show
  1. package/README.md +118 -0
  2. package/dist/index.js +3206 -0
  3. package/dist/types/commands/auth.d.ts +25 -0
  4. package/dist/types/commands/clean.d.ts +6 -0
  5. package/dist/types/commands/contribute.d.ts +139 -0
  6. package/dist/types/commands/finalize.d.ts +51 -0
  7. package/dist/types/commands/index.d.ts +9 -0
  8. package/dist/types/commands/listCeremonies.d.ts +5 -0
  9. package/dist/types/commands/logout.d.ts +6 -0
  10. package/dist/types/commands/observe.d.ts +22 -0
  11. package/dist/types/commands/setup.d.ts +86 -0
  12. package/dist/types/commands/validate.d.ts +8 -0
  13. package/dist/types/index.d.ts +2 -0
  14. package/dist/types/lib/errors.d.ts +60 -0
  15. package/dist/types/lib/files.d.ts +64 -0
  16. package/dist/types/lib/localConfigs.d.ts +110 -0
  17. package/dist/types/lib/prompts.d.ts +104 -0
  18. package/dist/types/lib/services.d.ts +31 -0
  19. package/dist/types/lib/theme.d.ts +42 -0
  20. package/dist/types/lib/utils.d.ts +158 -0
  21. package/dist/types/types/index.d.ts +65 -0
  22. package/package.json +99 -0
  23. package/src/commands/auth.ts +194 -0
  24. package/src/commands/clean.ts +49 -0
  25. package/src/commands/contribute.ts +1090 -0
  26. package/src/commands/finalize.ts +382 -0
  27. package/src/commands/index.ts +9 -0
  28. package/src/commands/listCeremonies.ts +32 -0
  29. package/src/commands/logout.ts +67 -0
  30. package/src/commands/observe.ts +193 -0
  31. package/src/commands/setup.ts +901 -0
  32. package/src/commands/validate.ts +29 -0
  33. package/src/index.ts +66 -0
  34. package/src/lib/errors.ts +77 -0
  35. package/src/lib/files.ts +102 -0
  36. package/src/lib/localConfigs.ts +186 -0
  37. package/src/lib/prompts.ts +748 -0
  38. package/src/lib/services.ts +191 -0
  39. package/src/lib/theme.ts +45 -0
  40. package/src/lib/utils.ts +778 -0
  41. package/src/types/conf.d.ts +16 -0
  42. package/src/types/index.ts +70 -0
@@ -0,0 +1,16 @@
1
+ declare module "conf" {
2
+ export interface ConfOptions {
3
+ projectName: string
4
+ schema: object
5
+ }
6
+
7
+ export class Conf {
8
+ constructor(options: ConfOptions)
9
+ get(key: string): any
10
+ set(key: string, value: any): void
11
+ delete(key: string): void
12
+ has(key: string): boolean
13
+ }
14
+
15
+ export default Conf
16
+ }
@@ -0,0 +1,70 @@
1
+ import { User as FirebaseAuthUser } from "firebase/auth"
2
+
3
+ /**
4
+ * Different custom progress bar types.
5
+ * @enum {string}
6
+ */
7
+ export enum ProgressBarType {
8
+ DOWNLOAD = "DOWNLOAD",
9
+ UPLOAD = "UPLOAD"
10
+ }
11
+
12
+ /**
13
+ * Define the current authenticated user in the Firebase app.
14
+ * @typedef {Object} AuthUser
15
+ * @property {FirebaseAuthUser} user - the instance of the Firebase authenticated user.
16
+ * @property {string} token - the access token.
17
+ * @property {string} providerUserId - the unique identifier of the user tied to its account from a third party provider (e.g., Github).
18
+ */
19
+ export type AuthUser = {
20
+ user: FirebaseAuthUser
21
+ token: string
22
+ providerUserId: string
23
+ }
24
+
25
+ /**
26
+ * Define a custom object for time management tasks.
27
+ * @typedef {Object} Timing
28
+ * @property {number} seconds
29
+ * @property {number} minutes
30
+ * @property {number} hours
31
+ * @property {number} days
32
+ */
33
+ export type Timing = {
34
+ seconds: number
35
+ minutes: number
36
+ hours: number
37
+ days: number
38
+ }
39
+
40
+ /**
41
+ * Define a custom object containing contribution verification data.
42
+ * @typedef {Object} VerifyContributionComputation
43
+ * @property {boolean} valid - true if the contribution is valid; otherwise false.
44
+ * @property {number} verificationComputationTime - the time spent for completing the verification task only.
45
+ * @property {number} verifyCloudFunctionTime - the time spent for the execution of the verify contribution cloud function.
46
+ * @property {number} fullContributionTime - the time spent while contributing (from download to upload).
47
+ */
48
+ export type VerifyContributionComputation = {
49
+ valid: boolean
50
+ verificationComputationTime: number
51
+ verifyCloudFunctionTime: number
52
+ fullContributionTime: number
53
+ }
54
+
55
+ /**
56
+ * Define a custom object containing a Github Gist file data.
57
+ * @typedef {Object} GithubGistFile
58
+ * @property {string} filename - the name of the file.
59
+ * @property {string} type - the type of the content of the file (e.g., text/plain).
60
+ * @property {string} language - the type of file (e.g, Text, Markdown).
61
+ * @property {string} raw_url - the url to file content.
62
+ * @property {number} size - the size of the file (in bytes).
63
+ */
64
+ export type GithubGistFile = {
65
+ filename: string
66
+ type: string
67
+ language: string
68
+ raw_url: string
69
+ size: number
70
+ }