Commit d5a86f0
committed
Install further packages automatically
PC has the notion of "dependent" or additional packages. These are
defined in a standard "Package Control.sublime-settings" file, hosted
by the package. (I.e. similar to the "dependencies.json".)
Installing such a package did not install the additional packages in one
go, neither did it notify about the incomplete install. In the end, a
restart is enough and required to trigger `install_missing_packages()`
to catch up and install everything.
We have two options here. (1) to bail out `install_package` with
`return None` and a message to tell the user to restart Sublime, or (2)
to install the packages in a recursive style.
Here we choose (2).
We patch `run_install_tasks` to notify about its outcome to fail the
parent task if necessary. This way necessary restarts bubble up.1 parent 904eb36 commit d5a86f0
2 files changed
+46
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| |||
1600 | 1601 | | |
1601 | 1602 | | |
1602 | 1603 | | |
| 1604 | + | |
| 1605 | + | |
| 1606 | + | |
| 1607 | + | |
| 1608 | + | |
| 1609 | + | |
| 1610 | + | |
| 1611 | + | |
| 1612 | + | |
| 1613 | + | |
| 1614 | + | |
| 1615 | + | |
| 1616 | + | |
| 1617 | + | |
| 1618 | + | |
| 1619 | + | |
| 1620 | + | |
| 1621 | + | |
| 1622 | + | |
| 1623 | + | |
| 1624 | + | |
| 1625 | + | |
| 1626 | + | |
| 1627 | + | |
| 1628 | + | |
| 1629 | + | |
| 1630 | + | |
| 1631 | + | |
| 1632 | + | |
| 1633 | + | |
| 1634 | + | |
| 1635 | + | |
| 1636 | + | |
| 1637 | + | |
| 1638 | + | |
| 1639 | + | |
| 1640 | + | |
1603 | 1641 | | |
1604 | 1642 | | |
1605 | 1643 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
362 | 362 | | |
363 | 363 | | |
364 | 364 | | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
365 | 369 | | |
366 | 370 | | |
367 | 371 | | |
| |||
384 | 388 | | |
385 | 389 | | |
386 | 390 | | |
| 391 | + | |
387 | 392 | | |
388 | 393 | | |
389 | 394 | | |
| |||
393 | 398 | | |
394 | 399 | | |
395 | 400 | | |
| 401 | + | |
396 | 402 | | |
397 | 403 | | |
398 | 404 | | |
| |||
412 | 418 | | |
413 | 419 | | |
414 | 420 | | |
| 421 | + | |
| 422 | + | |
415 | 423 | | |
416 | 424 | | |
417 | 425 | | |
| |||
0 commit comments