Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Faster add-on development workflow #5199

Closed
nvaccessAuto opened this issue Jul 6, 2015 · 4 comments
Closed

Faster add-on development workflow #5199

nvaccessAuto opened this issue Jul 6, 2015 · 4 comments
Labels
Addon/management In NVDA management of addons by users. enhancement

Comments

@nvaccessAuto
Copy link

Reported by Q on 2015-07-06 20:11
Currently, the options for developing an NVDA add-on consist of:

1: Create and work on the add-on in your standard code directory.
This is how I'd like to work, but it has some pretty major downsides.
When working on the code, test, debug lifecycle, the necessity of constantly having to run scons, then install the add-on and answer yes three times for every single change becomes incredibly wearing.
2: An ugly hack that several people have suggested is to place the actual add-on code into the add-ons directory and work on it there. This means not having access to the version control while working on the code, and manually having to copy code back and forth to the git repo. It's also just sort of downright ugly.

I suggest an improved version of 1:

If we can figure out where NVDA data should go, either by asking NVDA itself, asking the user, or even just guessing, we can automatically install the add-on without prompting the user. NVDA already has the ability to force restart. I propose a scons install command in the default add-on template, which may need to call infrastructure in the core to accomplish what it needs to to get the add-on installed and the current NVDA restarted.
I'm opening this here as my conversation with @joslee lead me to believe that this will need at least a bit of work in core.

@nvaccessAuto
Copy link
Author

Comment 2 by jteh on 2015-07-08 04:28
Another solution is to create an NTFS junction (using mklink) from the addon folder in your standard code directory to the appropriate directory in NVDA's addons directory. This way, you don't actually need to install the add-on after each change. As I understand it, this should give you all you're asking for.

I'm rather reluctant to add anything like this to the public API because while it's useful for development, public callers generally shouldn't be asking for this kind of information. I'm concerned it'll lead to external apps trying to make config changes or the like, and while they can already do that, it's at least not "encouraged" by the API. That said, I guess we could consider some sort of private API if that's really necessary.

I also think this should be named scons devInst or fastInst or something like that so it's clear it isn't a normal installation. For example, it doesn't run installTasks, etc.

For reference, there are three possible places NVDA can store its configuration:

  1. If the -c (--config-path) option is provided, it will use this directory.
  2. If that option isn't passed and it's running from within the system's Program Files, it's %appdata%\nvda.
  3. Otherwise, it's the userConfig folder inside the portable copy's directory.

@jcsteh jcsteh removed the Untriaged label Nov 13, 2015
@ehollig ehollig added the Addon/management In NVDA management of addons by users. label Dec 7, 2017
@Adriani90
Copy link
Collaborator

cc: @feerrenrut

@Adriani90
Copy link
Collaborator

cc: @michaelDCurran

@feerrenrut
Copy link
Contributor

II think I'll close this. At the moment you can use the scratchpad to avoid having to install the addon. You could link the directories as Jamie suggested, or you could use a directory synchronization tool to keep the scratch pad in sync with the addon repo. If you do this, then working on an addon from an IDE (opening the NVDA source code as a project, with the addon synchronized with the scratchpad directory) allows you to get hinting and instantly start and test the addon.

I think the first step should be for the addon community to get together docs on the suggested workflow for addon authors. From beginning to end. This will help to identify the friction points and we can work to do something about it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Addon/management In NVDA management of addons by users. enhancement
Projects
None yet
Development

No branches or pull requests

5 participants