summaryrefslogtreecommitdiffstats
path: root/gd_diff.py
diff options
context:
space:
mode:
authorrsiddharth <s@ricketyspace.net>2016-11-13 03:15:12 +0000
committerrsiddharth <s@ricketyspace.net>2016-11-13 03:15:12 +0000
commit2bc1c934c0e2c00757f5cce09074d5fcca3a64d0 (patch)
treeb86c04303c7b85ce8b1562a1ee562303a40e2081 /gd_diff.py
parentce9357afd361a609950957ec7fd274d67f7a3800 (diff)
Add `mk_pkgs_list` function.
* gd_diff.py (mk_pkgs_list): New function. * tests/test_gd_diff.py (test_mk_pkgs_list): Test for `mk_pkgs_list` function.
Diffstat (limited to 'gd_diff.py')
-rw-r--r--gd_diff.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/gd_diff.py b/gd_diff.py
index 23afe4e..8c802c6 100644
--- a/gd_diff.py
+++ b/gd_diff.py
@@ -241,6 +241,17 @@ def pkgs_dir():
return pd
+def mk_pkgs_list(release):
+ """Get pkgs for release and write to disk.
+
+ It gets written to `~/.config/pkgs/release`.
+
+ """
+ pkgs = get_packages(release)
+ pkgs_file = os.path.join(pkgs_dir(), release)
+ write_file(pkgs_file, pkgs)
+
+
def readmes_dir(release):
"""Return readmes directory for `release`.