@suitegeezus/suitecloud-stacker 25.2.129-5 → 25.2.129

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.
package/README.md CHANGED
@@ -1,62 +1,12 @@
1
1
  Contains helpers for SDF (Node CLI edition)
2
2
 
3
3
  # Features
4
- - Collection of pre-configured hooks (commands) to manage ACS problems withing customer account
4
+ - Collection of pre-configured hooks (commands) to manage customer accounts
5
5
  - Collection of pre-configured hooks to manage the outer project
6
6
  - Pre-defined handlers that you can pick and choose from for a given "command"
7
7
  - Types for SDF commands
8
8
  - command line enhancements
9
9
 
10
- Missing: Collection of hooks to manage an entire instance -- Cuz we (ACS) don't do this but if you have your own instance / demo account then feel free to create your own suitecloud.config file and use the stackable structure. Note that most customers don't really do this either -- they often have outside devs who contribute at least sometimes
11
-
12
- # Demos
13
-
14
- ## `account:setup:ci` : Token Auth Memory
15
- Setup token auth for an account from existing token auths that you have with detection for conflicts and valid naming
16
- ![example](./img/accountsetupci.example1.gif)
17
-
18
- ## `project:create`: New Account
19
- Create project to work on a case
20
- ![example](./img/projectcreate.example1.gif)
21
-
22
- ## `project:create`: New Case on Account
23
- ![example](./img/projectcreate.example2.gif)
24
-
25
- ## `file:upload`: Globbing that filters out irrelevant files
26
- ![example](./img/fileupload.example1.gif)
27
-
28
- ## `file:upload`: Upload all files from a deploy.xml file
29
- ![example](./img/fileupload.example3.gif)
30
-
31
- ## `file:upload`: Compile and / or run tests on files you are uploading
32
- ![example](./img/fileupload.example4.gif)
33
-
34
- ## `file:import`: Compare your current file with what is in the account
35
- ![example](./img/fileimport.example3.gif)
36
-
37
- ## `file:import`: Import files that match a glob pattern
38
- ![example](./img/fileimport.example2.gif)
39
-
40
- ## `file:import`: Import all files from a deploy.xml file
41
- ```shell
42
- cd /SuiteScripts/ACS/casefolder
43
- suitecloud file:import --paths ./deploy/deploy.xml
44
- ```
45
-
46
- ## `object:import`: import objects that match a glob pattern
47
- ![example](./img/objectimport.example1.gif)
48
-
49
- ## `object:import`: import all objects that are listed in a chosen deploy.xml file
50
- ![example](./img/objectimport.example2.gif)
51
-
52
- ## `project:deploy`: Choose which project definition to deploy
53
-
54
- ## `object:import`: Import Objects will organize them into folders by type automatically
55
- ![example](./img/objectOrganization.png)
56
-
57
- ## Compile and test typescript as you write
58
- ![example](./img/nodemon.example1.gif);
59
-
60
10
  # How SDF works in this project
61
11
 
62
12
  SDF by default has a certain structure that makes the following (annoying?) assumptions:
@@ -89,20 +39,10 @@ npm install -g nodemon
89
39
  4. Optional: Be able to sync repositories with ALM via OCNA
90
40
  - These are entitlements that will help you stay on the latest version of this repo and use customer repos
91
41
  - If you can't then you can still use this for your testdrive accounts -- just ask me how
92
- 5. Optional: define `oraclegit` in your ssh **config** (highly recommended)
93
- ```txt
94
- HOST oraclegit
95
- User gerald.gillespie@fullscript.com
96
- HostName alm.oraclecorp.com
97
- TCPKeepAlive yes
98
- AddKeysToAgent yes
99
- UseKeyChain yes
100
- IdentityFile ~/.ssh/ed25519ggoracle2
101
- ```
102
- 6. Optional: Create an environment variable for DIFF_TOOL
42
+ 5Optional: Create an environment variable for SUITECLOUD_DIFF_TOOL
103
43
  ```shell
104
- #➜ nsaccounts git:(main) ✗ set | grep 'DIFF'
105
- export DIFF_TOOL='/Applications/./IntelliJ\ IDEA.app/Contents/MacOS/idea'
44
+ #➜ set | grep 'DIFF'
45
+ export SUITECLOUD_DIFF_TOOL='/Applications/./IntelliJ\ IDEA.app/Contents/MacOS/idea'
106
46
  ```
107
47
 
108
48
  ### NetSuite pre-requisites
@@ -112,13 +52,10 @@ You will need to have:
112
52
  - SuiteScript, etc enabled
113
53
 
114
54
  ## Install on Mac / Linux / Windows
115
- 1. clone the repo (not the weird extra slash `:/` ALM needs)
116
- ```shell
117
- git clone oraclegit:/nscs_suitecloud-stacker_114170/suitecloud-stacker-root.git
118
- ```
119
- 2. Run npm install
55
+
56
+ Run npm install
120
57
  ```shell
121
- npm install
58
+ npm install @suitegeezus/suitecloud-stacker
122
59
  ```
123
60
 
124
61
  # Usage: Hello World Example
@@ -128,29 +65,8 @@ npm install
128
65
 
129
66
 
130
67
 
131
- ## Pre-Defined Stacks for the Common scenario
132
- - Collection of hooks meant for ACP subprojects (e.g. a specific case/ project)
133
- ```js
134
- const safeCommands = require('suitecloud-stacker/safeCommands.js');
135
- module.exports = {
136
- ...projectJson,
137
- commands: {...safeCommands.caseCommands},
138
- },
139
- {debug: false, block: false},
140
- module
141
-
142
- ```
143
-
144
- ### Spin up a new SDF project for a case
145
- You can use this command to create your own case
146
- ```bash
147
- cd ~/code/projectRoot
148
- suitecloud project:create
149
- # follow-the prompts
150
- ```
151
-
152
68
  ## Stackable / chaining structure for SDF command hooks
153
- This means your suitecloud.config.js can specify or replace commands something like this:
69
+ This means your sdf.config.js can specify or replace commands something like this:
154
70
 
155
71
  ```js
156
72
  const commands = {
@@ -175,33 +91,29 @@ Also, don't bother with the IDE plugins. not only do they have their own limitat
175
91
 
176
92
  This has the following usage
177
93
 
178
- ### `--authid`
179
- supports a format like this `2452352:wut` where the value before the `:` is the authid and the value after the colon is the folder name.
180
-
181
- if you only specify the first part without any colon then the same value is used for both. i.e. `2452352` is equivalent to `2452352:2452352`
182
-
183
- you can create this anywhere. Wherever you create it you should invoke it from there.
184
- e.g.
185
- ```bash
186
- cd FileCabinet/SuiteScripts/folder
187
- suitecloud
188
- ```
189
94
 
190
95
  ## working directory
191
- native `suitecloud` must be called from a directory that has a `suitecloud.config.js` file.
96
+ `sdf` must be called from a directory that has a `sdf.config.js` file.
192
97
 
193
- As such if you setup a project using native command and run it then it will work because that process will create a `suitecloud.config.js`.
98
+ As such if you setup a project using native command and run it then it will work because that process will create a `sdf.config.js`.
194
99
 
195
- It is recommended that you set your `suitecloud.config.js` file to be the following:
100
+ It is recommended that you set your `sdf.config.js` file to be the following:
196
101
 
197
102
  ```js
198
- const sdfAcs = require('./sdf/safeCommands');
103
+ const safeCommands = require('@suitegeezus/suitecloud-stacker/safeCommands');
199
104
 
200
105
  // create the commands that you want
201
106
  const commands = {};
202
107
 
203
- // pass them through the sdfAcs layer
204
- module.exports = sdfAcs.makeSuiteCloudConfig({commands});
108
+ // pass them through the stacker
109
+ safeCommands.makeSafeExports(
110
+ {
111
+ defaultProjectFolder: 'src',
112
+ commands: stackerCommands,
113
+ },
114
+ {debug: false, block: false, autoCreateProjectJson: false,},
115
+ module
116
+ );
205
117
  ```
206
118
 
207
119
  # Errors
@@ -223,20 +135,18 @@ This should also be true of objects.
223
135
 
224
136
  We can use SDF for both code (suitescripts) and objects.
225
137
 
226
- Regardless of how many sandboxen the customer has...
227
- Regardless of what weird branching strategies they might have... or don't have.
228
- Regardless of whether we are writing code for the customer's use or writing code the helps us create the solution for the customer...
229
- Regardless of how many cases are concurrently being worked on for a customer...
230
- When we write code or create objects it is hella convenient and powerful to have both under source control and to use merging strategies that support the work we are doing for the customer.
138
+ Regardless of how many sandboxen you have...
139
+ Regardless of what weird branching strategies you might have... or don't have.
140
+ When we write code or create objects it is hella convenient and powerful to have both under source control and to use merging strategies that support the work we are doing...
231
141
 
232
- In all of the above you can have a real "customer" or it could simply be a concept "customer"
142
+ In all of the above you can be end-user or a partner
233
143
 
234
- So we have one folder for a customer.
144
+ So we have one folder for an account.
235
145
 
236
- If a customer has multiple sandboxes then we probably have multiple branches but it doesn't matter. Our "master" branch is not the customer's master branch. It is our statement that this code is production worthy and ready to be vetted.
146
+ If you have sandboxes then we probably have multiple branches, but it doesn't matter. A "master" branch is our statement that this code is production worthy and ready to be vetted.
237
147
 
238
148
  ## But I don't want my customer to be a sub-folder in this project!
239
149
  You don't have to.
240
- There is nothing stopping you in git from (in fact it supports) having a subfolder be for a different repository. That repository can have different users. ESS member Bob can have a different set of accounts from Raffi and they can share any overlapping number of them. But when they want to collaborate on something in source control related to an account they can `pull` from a common view and still work independantly on separate branches and yet have full visibility into the other work.
150
+ There is nothing stopping you in git from (in fact it supports) having a subfolder be for a different repository.
241
151
 
242
152
  Further, the ability to `pull` from source control does not mean that you will be able to `file:deploy` to the customer account. You still need to have an authenticated token to do that. And that probably means you'll need to have login privileges to the customer's account (production, sandbox or whatever).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@suitegeezus/suitecloud-stacker",
3
- "version": "25.2.129-5",
3
+ "version": "25.2.129",
4
4
  "description": "SuiteCloud Stacker",
5
5
  "main": "safeCommands.js",
6
6
  "scripts": {
@@ -4,7 +4,7 @@
4
4
  /**
5
5
  * @file {1}
6
6
  * - only use this once per account
7
- * - this is auto-generated file based on a search of the account. See ESS query runner
7
+ * - this is auto-generated file based on a search of the account.
8
8
  * @author Gerald Gillespie <gerald.gillespie@fullscript.com>
9
9
  */
10
10