1

I installed flow server and atom IDE support for flow. https://atom.io/packages/ide-flow

If the flow command is not on your path, set its location in the package settings under Flow Path

I am on Windows system, I am not sure what path I need to set to get this working.

Nat Mote
  • 4,068
  • 18
  • 30
N Sharma
  • 33,489
  • 95
  • 256
  • 444

2 Answers2

1

To use the flow-bin installed in the projects node_modules dir, there is a setting in Nuclide:

Preferences... > Packages > nuclide > Settings > Nuclide-flow > Use the Flow binary included in each project's flow-bin

The security admonition stating "we will immediately run code" is not quite true, flow-bin seems to be executed only when you open a .js file in the editor. I guess it might be pertinent to ensure that the flow-bin is what you expecting before opening any files.

David
  • 728
  • 4
  • 20
  • I have already checked in my atom setting. when I restart my atom, everytime I get this message https://i.stack.imgur.com/7jJVI.png see this http://stackoverflow.com/questions/43407149/flow-was-not-found-when-attempting-to-start-atom-nuclide – N Sharma May 03 '17 at 04:53
  • Did you also install flow-bin following the instructions on the site linked the message? When you say that the flow server is working, how are you starting that? – David May 03 '17 at 09:35
  • I am starting it after launching the atom. Do I need to run this `npm run flow` before launching atom ? – N Sharma May 03 '17 at 09:54
  • I don't need to do that. As long as npm run flow works, it seems like atom should start it for you. Sorry I can't think of anything else, sounds like you've done everything that I did to get it working. – David May 03 '17 at 22:50
0

You can run

where flow

or maybe

where flow.exe

or

where flow.cmd

depending on how you have installed Flow. This will get you the full path to Flow.

Nat Mote
  • 4,068
  • 18
  • 30
  • I setup flow for my project https://medium.com/react-native-training/getting-started-with-react-native-and-flow-d40f55746809 When I am running suggested command then I am getting `INFO: Could not find files for the given pattern(s). ` – N Sharma Apr 17 '17 at 18:48
  • BTW flow is my application directory D:\React Native\Scheduled\node_modules\.bin but How I can set it in PATH so atom text editor will have access of it – N Sharma Apr 17 '17 at 18:51
  • Ah, if you installed a project-local flow-bin then it won't be accessible on the command line so this will not work. I don't know about `ide-flow`, but if you use Nuclide instead you can just enable a setting to use the project-local flow-bin and then you won't have to specify the path to the binary yourself. – Nat Mote Apr 17 '17 at 19:33
  • I am using Nuclide, How I can enable a setting to use project flow bin ? – N Sharma Apr 18 '17 at 04:37