blender-package-manager-addon.git
2 years agoMove package manager to blender branch master
Ellwood Zwovic [Tue, 29 Aug 2017 11:30:49 +0000 (04:30 -0700)]
Move package manager to blender branch

Moved the package manger out of an addon. It now lives here:
https://developer.blender.org/diffusion/B/browse/soc-2017-package_manager/

This repository still contains the repo generation script, the readme
has been updated to reflect this.

2 years agoRefresh package list after install
Ellwood Zwovic [Sun, 20 Aug 2017 08:20:23 +0000 (01:20 -0700)]
Refresh package list after install

2 years agoCorrect missed bit of rename
Ellwood Zwovic [Sun, 20 Aug 2017 07:52:28 +0000 (00:52 -0700)]
Correct missed bit of rename

2 years agoRepository filtering
Ellwood Zwovic [Sun, 20 Aug 2017 07:48:54 +0000 (00:48 -0700)]
Repository filtering

2 years agoAdd simple preferences display (just good enough to match functionality with addons...
Ellwood Zwovic [Sun, 20 Aug 2017 06:17:56 +0000 (23:17 -0700)]
Add simple preferences display (just good enough to match functionality with addons section)

2 years agoDon't force 'spawn' method, add explanation for workaround
Ellwood Zwovic [Sun, 20 Aug 2017 02:05:14 +0000 (19:05 -0700)]
Don't force 'spawn' method, add explanation for workaround

2 years agoDon't import things which import things which import bpy
Ellwood Zwovic [Sun, 20 Aug 2017 02:01:42 +0000 (19:01 -0700)]
Don't import things which import things which import bpy

2 years agoMerge branch 'windows-subprocess-fix'
Ellwood Zwovic [Sun, 20 Aug 2017 02:00:52 +0000 (19:00 -0700)]
Merge branch 'windows-subprocess-fix'

2 years agoIf bpy fails to import, assume we are in subprocess and only import subproc.py windows-subprocess-fix
Ellwood Zwovic [Tue, 15 Aug 2017 07:30:47 +0000 (00:30 -0700)]
If bpy fails to import, assume we are in subprocess and only import subproc.py

2 years agoUI Tweaks
Ellwood Zwovic [Tue, 15 Aug 2017 07:24:11 +0000 (00:24 -0700)]
UI Tweaks

From feedback on demo video: https://www.youtube.com/watch?v=b_iBVNmeBdM&lc=z13hfndjmzqmtpe0p234vroyex3fgbovp

2 years agoAlways draw uninstalled packages as enabled
Ellwood Zwovic [Mon, 14 Aug 2017 20:43:27 +0000 (13:43 -0700)]
Always draw uninstalled packages as enabled

2 years agoFix failure to store installation state, store repositories in a set
Ellwood Zwovic [Mon, 14 Aug 2017 20:39:38 +0000 (13:39 -0700)]
Fix failure to store installation state, store repositories in a set

2 years agoOptimize package metadata fetching; avoid checking if packages are installed every...
Ellwood Zwovic [Sun, 13 Aug 2017 02:42:51 +0000 (19:42 -0700)]
Optimize package metadata fetching; avoid checking if packages are installed every redraw

2 years agoInitial multiple repository support
Ellwood Zwovic [Sun, 13 Aug 2017 02:36:39 +0000 (19:36 -0700)]
Initial multiple repository support

And lots of code reshuffling which likely should've been done in
separate commits..

2 years agoFix bug where sometimes enabled packages could be displayed as disabled
Ellwood Zwovic [Thu, 3 Aug 2017 01:50:11 +0000 (18:50 -0700)]
Fix bug where sometimes enabled packages could be displayed as disabled

2 years agoUse bpy.app.binary_path_python as subprocess interpreter
Ellwood Zwovic [Wed, 2 Aug 2017 23:45:34 +0000 (16:45 -0700)]
Use bpy.app.binary_path_python as subprocess interpreter

2 years agoImprove user-level error messages
Ellwood Zwovic [Fri, 28 Jul 2017 05:33:08 +0000 (22:33 -0700)]
Improve user-level error messages

2 years agoRemoved unused addon preference properties
Ellwood Zwovic [Fri, 28 Jul 2017 00:27:42 +0000 (17:27 -0700)]
Removed unused addon preference properties

2 years agoFurther clarify testing instructions
Ellwood Zwovic [Fri, 28 Jul 2017 00:27:00 +0000 (17:27 -0700)]
Further clarify testing instructions

2 years agoUpdate readme to mention bundled addons and other things
Ellwood Zwovic [Fri, 28 Jul 2017 00:15:14 +0000 (17:15 -0700)]
Update readme to mention bundled addons and other things

2 years agoClean up action button display, and add enabling/disabling
Ellwood Zwovic [Thu, 27 Jul 2017 06:36:14 +0000 (23:36 -0700)]
Clean up action button display, and add enabling/disabling

2 years agoQuick hack to show 'update' instead of 'install' when appropriate
Ellwood Zwovic [Wed, 26 Jul 2017 09:28:00 +0000 (02:28 -0700)]
Quick hack to show 'update' instead of 'install' when appropriate

2 years agoFix wrong name errors caused in previous commit
Ellwood Zwovic [Wed, 26 Jul 2017 09:27:01 +0000 (02:27 -0700)]
Fix wrong name errors caused in previous commit

2 years agoCleanup: Move package download/install code out of subproc.py
Ellwood Zwovic [Wed, 26 Jul 2017 09:08:01 +0000 (02:08 -0700)]
Cleanup: Move package download/install code out of subproc.py

Instead do such things in bpkg, and only handle interfacing between
blender and bpkg in subproc.py

2 years agoUpdate readme to reflect new repo UI
Ellwood Zwovic [Tue, 25 Jul 2017 08:32:44 +0000 (01:32 -0700)]
Update readme to reflect new repo UI

2 years agoImplement more filter methods
Ellwood Zwovic [Tue, 25 Jul 2017 08:07:06 +0000 (01:07 -0700)]
Implement more filter methods

Add filtering by support level and installed/update-able

2 years agoTrack expanded packages outside of packages themseleves
Ellwood Zwovic [Tue, 25 Jul 2017 04:53:38 +0000 (21:53 -0700)]
Track expanded packages outside of packages themseleves

Packages now retain their expanded/collapsed state after the
packagelist has been regenerated.

2 years agoAdjust package state display
Ellwood Zwovic [Tue, 25 Jul 2017 02:03:10 +0000 (19:03 -0700)]
Adjust package state display

2 years agoDifferentiated between user packages and system packages
Ellwood Zwovic [Tue, 25 Jul 2017 01:47:21 +0000 (18:47 -0700)]
Differentiated between user packages and system packages

We usually can't uninstall system packages, so display them
differently

Also fixed some missing `global`s.

2 years agoAdd 'repo.json' to url before giving it to bpkg
Ellwood Zwovic [Tue, 25 Jul 2017 00:54:39 +0000 (17:54 -0700)]
Add 'repo.json' to url before giving it to bpkg

2 years agoRecursively reload submodules
Ellwood Zwovic [Tue, 25 Jul 2017 00:42:00 +0000 (17:42 -0700)]
Recursively reload submodules

2 years agoAdd repository list to package panel
Ellwood Zwovic [Mon, 24 Jul 2017 23:44:35 +0000 (16:44 -0700)]
Add repository list to package panel

Actually adding multiple repositories is disallowed for now

2 years agoMove 'all_packages' list out of the panel class
Ellwood Zwovic [Mon, 24 Jul 2017 21:17:43 +0000 (14:17 -0700)]
Move 'all_packages' list out of the panel class

This is used for more than drawing, so it doesn't belong on the panel.

2 years agoFix missing import
Ellwood Zwovic [Mon, 24 Jul 2017 21:17:06 +0000 (14:17 -0700)]
Fix missing import

2 years agoDocumentation: include testing repository
Ellwood Zwovic [Sun, 23 Jul 2017 07:14:47 +0000 (00:14 -0700)]
Documentation: include testing repository

2 years agoDocumentation: installation and setup instructions, and some notes
Ellwood Zwovic [Sun, 23 Jul 2017 06:47:40 +0000 (23:47 -0700)]
Documentation: installation and setup instructions, and some notes

2 years agoCorrect wrong bl_idname for preferences, trigger redraw after packagelist change
Ellwood Zwovic [Sun, 23 Jul 2017 04:42:22 +0000 (21:42 -0700)]
Correct wrong bl_idname for preferences, trigger redraw after packagelist change

2 years agoFix inport errors and maintain compatibility with python 3.5x)
Ellwood Zwovic [Sun, 23 Jul 2017 03:14:09 +0000 (20:14 -0700)]
Fix inport errors and maintain compatibility with python 3.5x)

2 years agoImprove metadata display
Ellwood Zwovic [Sun, 23 Jul 2017 01:44:44 +0000 (18:44 -0700)]
Improve metadata display

2 years agoUpdate bl_info
Ellwood Zwovic [Fri, 21 Jul 2017 07:36:55 +0000 (00:36 -0700)]
Update bl_info

2 years agoRemove hang operator
Ellwood Zwovic [Fri, 21 Jul 2017 07:29:47 +0000 (00:29 -0700)]
Remove hang operator

2 years agoMove package management code out of subproc.py
Ellwood Zwovic [Fri, 21 Jul 2017 07:27:16 +0000 (00:27 -0700)]
Move package management code out of subproc.py

2 years agoCleanup: rename package manager addon from bpkg -> package_manager
Ellwood Zwovic [Fri, 21 Jul 2017 06:05:13 +0000 (23:05 -0700)]
Cleanup: rename package manager addon from bpkg -> package_manager

As I see it, the *package manager* is called "bpkg", while the *package
manager addon* is called "package_manager".

The *package manager* contains the actual package management code, and
the *package manager addon* provides the interface to use it.

2 years agoCleanup: rename repo generation script
Ellwood Zwovic [Fri, 21 Jul 2017 05:58:17 +0000 (22:58 -0700)]
Cleanup: rename repo generation script

In attempt to keep this name short, it became acronym-y *and* long. Better
to just pick a clear name which tab-completes.

2 years agoCleanup: Rename ViewPackage -> ConsolidatedPackage in preparation for restructure
Ellwood Zwovic [Fri, 21 Jul 2017 04:38:06 +0000 (21:38 -0700)]
Cleanup: Rename ViewPackage -> ConsolidatedPackage in preparation for restructure

2 years agoAdd uninstall function and operator
Ellwood Zwovic [Fri, 21 Jul 2017 02:22:45 +0000 (19:22 -0700)]
Add uninstall function and operator

For now the install/uninstall operators only operate on the newest
available version of a given package.

2 years agoDon't leave trailing slashes on the end of directory names
Ellwood Zwovic [Fri, 21 Jul 2017 01:06:42 +0000 (18:06 -0700)]
Don't leave trailing slashes on the end of directory names

2 years agoMake it easy to re-collapse packages after expanding many at once
Ellwood Zwovic [Thu, 20 Jul 2017 08:34:24 +0000 (01:34 -0700)]
Make it easy to re-collapse packages after expanding many at once

2 years agoInclude installed packages in listing
Ellwood Zwovic [Thu, 20 Jul 2017 05:24:27 +0000 (22:24 -0700)]
Include installed packages in listing

2 years agoFilelist should just include filenames, not absolute path to the file!
Ellwood Zwovic [Thu, 20 Jul 2017 02:18:20 +0000 (19:18 -0700)]
Filelist should just include filenames, not absolute path to the file!

2 years agoStore filelists in generated repositories
Ellwood Zwovic [Wed, 19 Jul 2017 23:51:32 +0000 (16:51 -0700)]
Store filelists in generated repositories

2 years agoAllow user-added urls to omit 'repo.json'
Ellwood Zwovic [Wed, 19 Jul 2017 06:02:34 +0000 (23:02 -0700)]
Allow user-added urls to omit 'repo.json'

2 years agoDon't show install button if there's no URL to install from
Ellwood Zwovic [Wed, 19 Jul 2017 01:36:58 +0000 (18:36 -0700)]
Don't show install button if there's no URL to install from

2 years agoJust ignore missing blinfo fields
Ellwood Zwovic [Wed, 19 Jul 2017 01:35:48 +0000 (18:35 -0700)]
Just ignore missing blinfo fields

2 years agoStore repository on window manager so it isn't saved in the .blend
Ellwood Zwovic [Wed, 19 Jul 2017 01:25:53 +0000 (18:25 -0700)]
Store repository on window manager so it isn't saved in the .blend

We store it outside blender in JSON anyway, storing it two places at
once could be confusing. We can move it back into the .blend later if it
seems that would be preferred.

2 years agoRemove commented attempt at caching search results
Ellwood Zwovic [Wed, 19 Jul 2017 00:32:03 +0000 (17:32 -0700)]
Remove commented attempt at caching search results

We need to store sorted list of ID/names of packages rather than packages themselves, otherwise we miss changes such as "collapsed/expanded"

2 years agoBetter sorting of search results
Ellwood Zwovic [Wed, 19 Jul 2017 00:30:42 +0000 (17:30 -0700)]
Better sorting of search results

2 years agoSome odd tweaks and repo management code
Ellwood Zwovic [Tue, 18 Jul 2017 22:10:11 +0000 (15:10 -0700)]
Some odd tweaks and repo management code

2 years agoPartial expanded view implementation
Ellwood Zwovic [Sat, 15 Jul 2017 09:18:18 +0000 (02:18 -0700)]
Partial expanded view implementation

Not all metadata is correctly displayed yet

2 years agoAddress comments on 2e45bf637aa3
Ellwood Zwovic [Sat, 15 Jul 2017 04:15:00 +0000 (21:15 -0700)]
Address comments on 2e45bf637aa3

2 years agoException handling for repo refresh
Ellwood Zwovic [Sat, 15 Jul 2017 03:26:03 +0000 (20:26 -0700)]
Exception handling for repo refresh

2 years agoAddress comments on 058b5a802f27
Ellwood Zwovic [Sat, 15 Jul 2017 02:22:53 +0000 (19:22 -0700)]
Address comments on 058b5a802f27

Also address some from 67b1857e58cc which got left out of the previous
commit

2 years agoAddress comments on 67b1857e58cc
Ellwood Zwovic [Sat, 15 Jul 2017 01:02:52 +0000 (18:02 -0700)]
Address comments on 67b1857e58cc

2 years agoAdd setup.py
Ellwood Zwovic [Sat, 15 Jul 2017 00:16:00 +0000 (17:16 -0700)]
Add setup.py

2 years agoRename bpkg_manager to just bpkg
Ellwood Zwovic [Sat, 15 Jul 2017 00:13:40 +0000 (17:13 -0700)]
Rename bpkg_manager to just bpkg

2 years agoGive repo generation tool clearer name
Ellwood Zwovic [Sat, 15 Jul 2017 00:09:30 +0000 (17:09 -0700)]
Give repo generation tool clearer name

2 years agoAdd pytest .cache dirs to gitignore
Ellwood Zwovic [Fri, 14 Jul 2017 23:13:30 +0000 (16:13 -0700)]
Add pytest .cache dirs to gitignore

2 years agoRemove old code
Ellwood Zwovic [Fri, 14 Jul 2017 23:12:35 +0000 (16:12 -0700)]
Remove old code

2 years agoAdd baseurl option to make_repo and actually set package urls
Ellwood Zwovic [Fri, 14 Jul 2017 07:56:34 +0000 (00:56 -0700)]
Add baseurl option to make_repo and actually set package urls

Also actually use said URL when calling 'install' operator

2 years agoBasic filtering for package browser
Ellwood Zwovic [Fri, 14 Jul 2017 07:23:26 +0000 (00:23 -0700)]
Basic filtering for package browser

2 years agoSort packagelist
Ellwood Zwovic [Fri, 14 Jul 2017 05:32:51 +0000 (22:32 -0700)]
Sort packagelist

2 years agoBasic package browsing UI
Ellwood Zwovic [Fri, 14 Jul 2017 05:19:09 +0000 (22:19 -0700)]
Basic package browsing UI

2 years agoSend repolist to blender and list contents
Ellwood Zwovic [Fri, 14 Jul 2017 02:06:31 +0000 (19:06 -0700)]
Send repolist to blender and list contents

2 years agoRepository downloading
Ellwood Zwovic [Thu, 13 Jul 2017 23:33:14 +0000 (16:33 -0700)]
Repository downloading

2 years agoAddress comments on previous commit
Ellwood Zwovic [Thu, 13 Jul 2017 18:16:31 +0000 (11:16 -0700)]
Address comments on previous commit

2 years agoMake install procedure overwrite existing addons
Ellwood Zwovic [Thu, 13 Jul 2017 03:07:20 +0000 (20:07 -0700)]
Make install procedure overwrite existing addons

However, back them up first and restore them if anything goes wrong

2 years agoOnly check root files for conflicts
Ellwood Zwovic [Wed, 12 Jul 2017 22:03:12 +0000 (15:03 -0700)]
Only check root files for conflicts

2 years agoBasic install function
Ellwood Zwovic [Wed, 12 Jul 2017 05:39:31 +0000 (22:39 -0700)]
Basic install function

3 years agoSome stuff from old exception-based error handling approach
Ellwood Zwovic [Mon, 10 Jul 2017 01:59:36 +0000 (18:59 -0700)]
Some stuff from old exception-based error handling approach

3 years agoMerge branch 'master' of git.blender.org:blender-package-manager-addon
Ellwood Zwovic [Mon, 10 Jul 2017 00:31:36 +0000 (17:31 -0700)]
Merge branch 'master' of git.blender.org:blender-package-manager-addon

3 years agoAdded bpkg_manager package that can download packages in a subprocess
Sybren A. Stüvel [Sun, 9 Jul 2017 23:44:54 +0000 (01:44 +0200)]
Added bpkg_manager package that can download packages in a subprocess

Also contains a SubprocMixin mix-in class that can help to write
operators that run & monitor subprocesses.

Messages sent back & forth between Blender and the subprocess MUST subclass
either BlenderMessage or SubprocMessage.

3 years agoAlso raise exception on child process, to get a traceback for debugging
Ellwood Zwovic [Sun, 9 Jul 2017 22:10:00 +0000 (15:10 -0700)]
Also raise exception on child process, to get a traceback for debugging

I initially thought I could pass the traceback with the exception, but
it seems transmitting exceptions around with their tracebacks intact is
not so easy. There's a library which does this:

https://github.com/ionelmc/python-tblib

But this doesn't seem important enough to introduce a dependency..

3 years agoNote reasoning behind call order
gandalf3 [Sun, 9 Jul 2017 21:57:22 +0000 (14:57 -0700)]
Note reasoning behind call order

3 years agoAdd docstrings
gandalf3 [Sun, 9 Jul 2017 21:49:34 +0000 (14:49 -0700)]
Add docstrings

3 years agoAdd decorator for handing child-process side of pipe
gandalf3 [Sun, 9 Jul 2017 21:40:56 +0000 (14:40 -0700)]
Add decorator for handing child-process side of pipe

3 years agoSubprocess management: use a decorator
gandalf3 [Sun, 9 Jul 2017 00:51:41 +0000 (17:51 -0700)]
Subprocess management: use a decorator

Use a decorator instead of a mixin to handle subprocess spawning and
monitoring

3 years agoSplit addon code up by purpose
gandalf3 [Sat, 8 Jul 2017 00:56:49 +0000 (17:56 -0700)]
Split addon code up by purpose

3 years agoRename "blenderpack" module to "bpackage"
gandalf3 [Fri, 7 Jul 2017 05:58:17 +0000 (22:58 -0700)]
Rename "blenderpack" module to "bpackage"

Also split code into files by class

3 years agoMove blenderpack into own package
gandalf3 [Fri, 7 Jul 2017 05:22:58 +0000 (22:22 -0700)]
Move blenderpack into own package

3 years agoUpdate tests for previous commit
gandalf3 [Fri, 7 Jul 2017 05:12:43 +0000 (22:12 -0700)]
Update tests for previous commit

3 years agoAdd Repository and Package classes
gandalf3 [Fri, 7 Jul 2017 05:10:26 +0000 (22:10 -0700)]
Add Repository and Package classes

3 years agoRemove unneccesary bulk of code in addons used for testing
gandalf3 [Thu, 6 Jul 2017 07:00:43 +0000 (00:00 -0700)]
Remove unneccesary bulk of code in addons used for testing

3 years agoCleanup: Changes suggested by @sybren
gandalf3 [Thu, 6 Jul 2017 01:40:32 +0000 (18:40 -0700)]
Cleanup: Changes suggested by @sybren

3 years agoFirst test for conditional requests
gandalf3 [Wed, 5 Jul 2017 09:45:30 +0000 (02:45 -0700)]
First test for conditional requests

Involves lots of mocking. Part of the issue is that there is no way (?) to
know where repo.json is stored when blender isn't running the show.

3 years agoImprove make_repo.py
gandalf3 [Wed, 5 Jul 2017 06:56:19 +0000 (23:56 -0700)]
Improve make_repo.py

This cleans up make_repo.py a bit, using file extensions to determine
file type.

This also loosens the testing repo generation, as the existing
test required matching a predifed expected output which had to be
updated on every change (essentially making it a moot test, as the
reference output was obtained from the functions output).
The new test just checks if the output has the same number of packages
as the input dir has addons.

Tips on how best to test these sorts of "higher level" functions (if at
all) would be welcome :)

3 years agoRemove old commented code
gandalf3 [Tue, 4 Jul 2017 10:06:34 +0000 (03:06 -0700)]
Remove old commented code

3 years agoAdd UIlist for repositories (and make reloadable)
gandalf3 [Tue, 4 Jul 2017 09:11:03 +0000 (02:11 -0700)]
Add UIlist for repositories (and make reloadable)

3 years agoTerminology: Update -> Upgrade, Fetch -> Refresh
gandalf3 [Mon, 3 Jul 2017 01:47:15 +0000 (18:47 -0700)]
Terminology: Update -> Upgrade, Fetch -> Refresh

3 years agoQuick hack to handle case of non-text, non-python files
gandalf3 [Mon, 3 Jul 2017 01:39:58 +0000 (18:39 -0700)]
Quick hack to handle case of non-text, non-python files

3 years agoGet all tests for make_repo.py passing
gandalf3 [Sun, 2 Jul 2017 23:55:17 +0000 (16:55 -0700)]
Get all tests for make_repo.py passing