[med-svn] [Git][med-team/gjh-asl-json][master] 6 commits: Fix watchfile to detect new versions on github

Andreas Tille (@tille) gitlab at salsa.debian.org
Sun Jan 16 17:51:57 GMT 2022



Andreas Tille pushed to branch master at Debian Med / gjh-asl-json


Commits:
249728d3 by Andreas Tille at 2022-01-16T18:20:38+01:00
Fix watchfile to detect new versions on github

- - - - -
3590359f by Andreas Tille at 2022-01-16T18:20:42+01:00
routine-update: New upstream version

- - - - -
064f5c53 by Andreas Tille at 2022-01-16T18:20:43+01:00
New upstream version 0.0+git20210628.867c5da
- - - - -
1b13bc3e by Andreas Tille at 2022-01-16T18:20:43+01:00
Update upstream source from tag 'upstream/0.0+git20210628.867c5da'

Update to upstream version '0.0+git20210628.867c5da'
with Debian dir 26016759ec007a8bb07e9381382cbf0c4cb80c3f
- - - - -
a5d91740 by Andreas Tille at 2022-01-16T18:20:43+01:00
routine-update: Standards-Version: 4.6.0

- - - - -
f0626e32 by Andreas Tille at 2022-01-16T18:22:28+01:00
routine-update: Ready to upload to unstable

- - - - -


6 changed files:

- debian/changelog
- debian/control
- debian/watch
- src/AmplInterface.cpp
- src/AmplInterface.hpp
- src/gjh_asl_json.cpp


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,18 @@
+gjh-asl-json (0.0+git20210628.867c5da-1) unstable; urgency=medium
+
+  * Team upload.
+  * New upstream version
+  * Standards-Version: 4.6.0 (routine-update)
+
+ -- Andreas Tille <tille at debian.org>  Sun, 16 Jan 2022 18:21:03 +0100
+
+gjh-asl-json (0.0+git20180428.eb8720e-3) UNRELEASED; urgency=medium
+
+  * Team upload.
+  * Fix watchfile to detect new versions on github
+
+ -- Andreas Tille <tille at debian.org>  Sun, 16 Jan 2022 18:20:38 +0100
+
 gjh-asl-json (0.0+git20180428.eb8720e-2) unstable; urgency=medium
 
   * Team upload.


=====================================
debian/control
=====================================
@@ -5,7 +5,7 @@ Maintainer: Debian Med Packaging Team <debian-med-packaging at lists.alioth.debian.
 Uploaders: Andrei Rozanski <rozanski.andrei at gmail.com>
 Build-Depends: debhelper-compat (= 13),
                 libamplsolver-dev
-Standards-Version: 4.5.0
+Standards-Version: 4.6.0
 Homepage: https://github.com/ghackebeil/gjh_asl_json
 Vcs-Browser: https://salsa.debian.org/med-team/gjh-asl-json
 Vcs-Git: https://salsa.debian.org/med-team/gjh-asl-json.git


=====================================
debian/watch
=====================================
@@ -5,4 +5,4 @@ opts="mode=git,pretty=0.0+git%cd.%h" \
 
 # Upstream has no release tags
 #opts="filenamemangle=s%(?:.*?)?v?(\d[\d.]*)\.tar\.gz%@PACKAGE at -$1.tar.gz%" \
-#https://github.com/ghackebeil/gjh_asl_json/releases .*/archive/v?@ANY_VERSION@\.tar\.gz
+#https://github.com/ghackebeil/gjh_asl_json/releases .*/v?@ANY_VERSION@\.tar\.gz


=====================================
src/AmplInterface.cpp
=====================================
@@ -21,6 +21,7 @@ AmplInterface::AmplInterface(int argc, char**& argv)
    primal_assumed_(1.0),
    dual_assumed_(1.0),
    stubname_(""),
+   jsonname_(""),
    objn_(-1),
    obj_sense_(0),
    nnz_hes_lag_(-1)
@@ -46,7 +47,7 @@ AmplInterface::AmplInterface(int argc, char**& argv)
    Oinfo_ptr_->sname = new char[strlen(sname)+1];
    strcpy(Oinfo_ptr_->sname, sname);
 
-   char bsname[] = "gjh_asl_json: Version 1.0.0";
+   char bsname[] = "gjh_asl_json: Version 1.1.0";
    Oinfo_ptr_->bsname = new char[strlen(bsname)+1];
    strcpy(Oinfo_ptr_->bsname, bsname);
 
@@ -57,6 +58,7 @@ AmplInterface::AmplInterface(int argc, char**& argv)
    int options_count = 5;
    char* rows_res(NULL);
    char* cols_res(NULL);
+   char* json_res(NULL);
    keyword keywords[] = {/* must be alphabetical */
       /* one may notice that I'm going overboard here to shut up warnings
 	 about 'deprecated conversion from string const to char*' */
@@ -72,6 +74,10 @@ AmplInterface::AmplInterface(int argc, char**& argv)
          C_val,
          &cols_res,
          const_cast<char*>("Map of variable names to variable ids")),
+      KW(const_cast<char*>("json"),
+         C_val,
+         &json_res,
+         const_cast<char*>("Name of output JSON file")),
       KW(const_cast<char*>("rows"),
          C_val,
          &rows_res,
@@ -141,6 +147,11 @@ AmplInterface::AmplInterface(int argc, char**& argv)
 
    _ASSERT_(stub != NULL, "ASL Error: nl filename pointer is NULL");
    stubname_ = std::string(stub);
+   if (json_res) {
+      jsonname_ = std::string(json_res);
+   } else {
+      jsonname_ = stubname_ + ".json";
+   }
 
    FILE* nl = NULL;
    nl = jac0dim(stub, (int)strlen(stub));


=====================================
src/AmplInterface.hpp
=====================================
@@ -39,6 +39,9 @@ public:
    // get the nl file stub name
    std::string get_stubname() const {return stubname_;}
 
+   // get the output json file name
+   std::string get_jsonname() const {return jsonname_;}
+
    // write a sol file
    void write_solution_file();
 
@@ -126,6 +129,9 @@ private:
    // stub file name
    std::string stubname_;
 
+   // json file name
+   std::string jsonname_;
+
    // keep track if which objective is being used
    int objn_;
 


=====================================
src/gjh_asl_json.cpp
=====================================
@@ -7,7 +7,7 @@ int main(int argc, char** argv)
 {
    AmplInterface solver(argc, argv);
 
-   std::string output_name = solver.get_stubname()+".json";
+   std::string output_name = solver.get_jsonname();
 
    std::ofstream out;
    out.open(output_name.c_str(), std::ios::out | std::ios::trunc);



View it on GitLab: https://salsa.debian.org/med-team/gjh-asl-json/-/compare/44e4eec57090420111917da4edcfb14a3b12fb2a...f0626e32bd94f63c7afd66fe5c873ee1b4362499

-- 
View it on GitLab: https://salsa.debian.org/med-team/gjh-asl-json/-/compare/44e4eec57090420111917da4edcfb14a3b12fb2a...f0626e32bd94f63c7afd66fe5c873ee1b4362499
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20220116/7ae44501/attachment-0001.htm>


More information about the debian-med-commit mailing list