@idlesummer/tasker 0.1.0 → 0.1.2

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 (2) hide show
  1. package/README.md +7 -9
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -7,7 +7,7 @@ A simple, lightweight task pipeline runner with CLI spinners and formatters for
7
7
 
8
8
  ## What's This?
9
9
 
10
- Basically, it's a simple way to run tasks in sequence with nice terminal spinners. I got tired of writing the same boilerplate for build scripts, so I made this. Think of it like a mini task runner - simpler than Gulp but more structured than a bash script.
10
+ Basically, it's a simple way to run tasks in sequence with nice terminal spinners. The standard imperative way of writing build scripts seemed unelegant and I wanted something more functional/declarative, so I made this. Think of it like a mini task runner - simpler and lighter than Listr2 but more structured than a bash script.
11
11
 
12
12
  ## Features
13
13
 
@@ -56,7 +56,7 @@ That's it! You get:
56
56
 
57
57
  ## Why Would I Use This?
58
58
 
59
- Good question! Use this if you:
59
+ Use this if you:
60
60
  - Want to build a simple CLI tool or build script
61
61
  - Like seeing spinners while stuff happens
62
62
  - Need tasks to share data between each other
@@ -69,8 +69,6 @@ Don't use this if you:
69
69
 
70
70
  ## Documentation
71
71
 
72
- I wrote pretty detailed docs with a casual tone (because formal docs are boring):
73
-
74
72
  - **[API Reference](./docs/API.md)** - All the functions and types explained
75
73
  - **[Examples](./docs/EXAMPLES.md)** - Real code you can copy-paste
76
74
  - **[Architecture](./docs/ARCHITECTURE.md)** - How it works under the hood
@@ -113,12 +111,12 @@ Create a pipeline with tasks:
113
111
  const pipeline = pipe([
114
112
  {
115
113
  name: 'Task name',
114
+ onSuccess: (ctx, duration) => 'Custom success message',
115
+ onError: (error) => 'Custom error message',
116
116
  run: async (ctx) => {
117
117
  // Do stuff
118
118
  return { key: 'value' } // Updates context
119
119
  },
120
- onSuccess: (ctx, duration) => 'Custom success message',
121
- onError: (error) => 'Custom error message'
122
120
  }
123
121
  ])
124
122
 
@@ -161,10 +159,10 @@ const build = pipe([
161
159
  },
162
160
  {
163
161
  name: 'Compile TypeScript',
162
+ onSuccess: () => 'TypeScript compiled successfully',
164
163
  run: async () => {
165
164
  await execAsync('tsc')
166
165
  },
167
- onSuccess: () => 'TypeScript compiled successfully'
168
166
  },
169
167
  {
170
168
  name: 'Show output',
@@ -194,7 +192,7 @@ These might get fixed eventually, or they might not. PRs welcome if you want to
194
192
 
195
193
  ## Contributing
196
194
 
197
- Found a bug? Want to add a feature? Awesome!
195
+ Found a bug? Want to add a feature?
198
196
 
199
197
  1. Check [CONTRIBUTING.md](./docs/CONTRIBUTING.md) for guidelines
200
198
  2. Open an issue or PR
@@ -204,7 +202,7 @@ Even if you're new to open source, feel free to contribute. I'm learning too!
204
202
 
205
203
  ## License
206
204
 
207
- MIT - do whatever you want with this.
205
+ MIT - See [LICENSE](LICENSE) file
208
206
 
209
207
  ## Questions?
210
208
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@idlesummer/tasker",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "A simple task pipeline runner with CLI spinners and formatters",
5
5
  "keywords": [
6
6
  "task",