{"bugs":{"url":"https://github.com/havardh/workflow/issues"},"dist":{"shasum":"cfd3d956697dbce5937917bbe8d5b69184d1f3b9","tarball":"https://registry.npmjs.org/workflow-core/-/workflow-core-0.1.0-beta.0.tgz","fileCount":4,"integrity":"sha512-rrXHGqXRBtYMyNnSDHrsqZnckK3zzCqoZ3xd9DX4yHyIPt0uF7r2w33dYUghOJf9iEHstxxgPIeptmwNLRVs/g==","signatures":[{"sig":"MEUCID1/vVfuvMb3TC0p/gm/hxdueiFRPgQEoaRpDuOVVQk6AiEArpLeXe9T08f1ivfdugtsPMF2QJ/Vsrzx4XCHh+Aaq+M=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7666,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbHsJMCRA9TVsSAnZWagAAgNEP/RdDELAPLBuNaBXmtvcg\ntcq1l5kJjQIBIH8EqZcmeQL+4lg0NbqWl4+3fkfA+2NuKw0EVOMZGBg3T83S\njObPZ6RJbmJbIaL0kQtx/wd9sXtSNZjqU4lJq64OCilcxTUTM10ih0z5slI2\nQD6B8RIs+qJZrLT83Q0fzOc9MIDObxpk+egN66MHgUYVNmyJTbtVpW9yYGAI\nBb+4DSHOrBSFwBr+R/HZxXzAbB4HT/NDBKFabnP6hj1/O1oGls/XbZAhxlL/\nT1AVVP8vviZaXJytjpxwQVPxixq+PZH7WT+ZgbE9RtXL1KtzIKVp2ztARurS\nfEVs+OmHdnYl/6fISmA1y/bpV6E/0GbX6NlwBFeraZdbavTVNWzaYPd8SJxF\nCoQWYoAfZa8qS6YkEeVVai4tncm7+C06sYjNuabxoQXr0uyfLvAyNzyIjz4Y\n2T7lAwGloMBn9+AvCV8ZIbMXvh0EscUEEROCfZE7FBI/1c8Jwy/FQ4umcI10\no1CbtzVYVL7okwk5Lj3a5e17xSOp3e2yBkCigP+vQINVambwib+0Gi0n8paK\nCW1omHWbWoW+suK11gyCFFA1szrY+9SqbYyr4E13R0tIgOiacRpHT7+aU9Nr\na4E/KXa68nH2R5Lzj5udbvQTZU3X20U4bI5L+KAMwULIKUeDB5JZ8aa+c1x+\nfMID\r\n=NXHZ\r\n-----END PGP SIGNATURE-----\r\n"},"main":"index.js","name":"workflow-core","files":["dist","cli.js","index.js"],"author":{"name":"Håvard Wormdal Høiby","email":"havardwhoiby@gmail.com"},"readme":"# workflow-core\n\nWorkflow is an experimental workspace manager. Workflow aims to simplify navigating\ncomplex window configurations. It does so by letting the user define layouts and\na way to easily navigate between them. Workflow is meant to be an abstraction\nlayer on top of window managers like i3, awesome, and the proprietary ones found in\nOSX and Windows.\n\n## Are we crOSs yet?\n\n| OS/wm        | Status              |\n|--------------|---------------------|\n| i3           | Beta            |\n| windows      | Beta            |\n| OSX          | [In Progress](https://github.com/havardh/workflow/issues/3)   |\n| awesome      | [Up for grabs](https://github.com/havardh/workflow/issues/8)  |\n| Ubuntu/Unity | [In Progress](https://github.com/havardh/workflow/pull/24) |\n\n\n## Example\n\nLets say you are writing code in a TTD fashion and want to see both code, tests and\ntest execution at the same time:\n\n```\n|-Atom-[add.js]------|-Atom-[add_test.js]-|\n| add(a, b) {        | test_add_one() {   |\n|  return a+b;       |   n = add(1, 1);   |\n| }                  |   assert(n == 2);  |\n|                    |                    |\n|                    |                    |\n|--XTerm----------------------------------|\n| > 1 tests passed                        |\n|                                         |\n|                                         |\n|-----------------------------------------|\n```\n\nNow your layout consist of two instances of Atom one with code and one\nwith tests, and a terminal running the tests. To achieve this in workflow\nwe would add a layout file for this purpose:\n\n```js\nconst workspace : WorkspaceConfig = {\n  name: 'advisor:unit-test',\n  args: 'file',\n  root: SplitV({\n    percent: 1.0,\n    children: [\n      SplitH({\n        percent: 0.8,\n        children: [\n          Atom({\n            percent: 0.5,\n            folder: ({ file }) => projectRoot(file),\n            file: ({ file }) => file,\n            open: ({ file }) => `atom -n ${file}`,\n          }),\n          Atom({\n            percent: 0.5,\n            folder: ({ file }) => projectRoot(file),\n            file: ({ file }) => getTestFile(file),\n            open: ({ file }) => `atom -n ${file}`,\n          }),\n        ],\n      }),\n      XTerm({\n        percent: 0.2,\n        cwd: ({ file }) => projectRoot(file),\n        cmd: 'npm run watch:test:base --',\n        args: [\n          ({ file }) => getTestFile(file),\n        ],\n        open: ({ cwd, cmd, args }) => `cd ${cwd} && xterm -T '${cmd} ${args.join(' ')}' -e '${cmd} ${args.join(' ')}'`,\n      }),\n    ],\n  }),\n};\n```\n\nThe layout file contains a lot of detail, but the main points are the `args` property at the top\nand the  three `apps` containing the definition for how to open the three various programs.\n\nEach `workspace` specifies an optional list of arguments, in this case a single argument called\n`file`. These arguments will be available to the rest of the configuration.\n\nEach 'app' has a single important property, the `open` function. This method tells\n`workflow` how to open the app. In addition to the `open` function the app can specify\na number of application specific properties. `workflow` will use the arguments for the configuration\nand construct all the application specific properties. They will be passed to the `open` function to\nconstruct a single command used for opening the app.\n\nTo start this layout run the `yarn start` command with the layout and the source file as an\nargument. Try the following...\n\n```\nyarn start -- jsTest add.js\n```\n\nThe full example can be found [here](examles/js-test.js):\n\n## Usage\n\n```\nyarn\nyarn start -- <options>\n```\n\n### Development\n\n```shell\nyarn run test  # Run tests\nyarn run flow  # Run type checker\nyarn run eslint . # Run lint\n```\n\n## Documentation\n\n```\n\nconst config = {\n\n  resolvers: [\n    {\n      resolve: function(path) {\n        // Returns the absolute path of a flow found with the `path` argument.\n        // Throws an error if the flow is not found or is a directory.\n      },\n      alternatives: function(path) {\n        // Returns a list of possible flows filtered by the path argument.\n        // Throws an error if the path or dirname(path) is not a directory.\n        // Returns an empty list if no files are found.\n      }\n    }\n  ]\n\n};\n\n```\n","license":"MIT","scripts":{"start":"node cli.js"},"_npmUser":{"name":"havardh","email":"havardwhoiby@gmail.com"},"homepage":"https://github.com/havardh/workflow#readme","keywords":["wm","i3","osx","windows"],"repository":{"url":"git+https://github.com/havardh/workflow.git","type":"git"},"_npmVersion":"5.7.1","description":"Workflow-centric workspace manager","directories":{},"maintainers":[{"name":"havardh","email":"havardwhoiby@gmail.com"}],"_nodeVersion":"8.4.0","_hasShrinkwrap":false,"readmeFilename":"readme.md","_npmOperationalInternal":{"tmp":"tmp/workflow-core_0.1.0-beta.0_1528742474805_0.4378795646645186","host":"s3://npm-registry-packages"},"_id":"workflow-core@0.1.0-beta.0","version":"0.1.0-beta.0"}