kopia lustrzana https://github.com/jamescoxon/dl-fldigi
Upload the git commit as a version in listener_info
rodzic
e66a318406
commit
cfdf9368de
|
@ -23,6 +23,7 @@ src/flarq
|
|||
src/fldigi
|
||||
src/dl-fldigi
|
||||
src/stamp-h1
|
||||
src/dl_fldigi/version.cxx
|
||||
|
||||
# Runtime generated files
|
||||
dl-fldigi-waterfall.png
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
FILE=../src/dl_fldigi/version.cxx
|
||||
|
||||
COMMIT=`git log -1 | head -n1 | cut -d ' ' -f2`
|
||||
SHORT_COMMIT=`git log -1 --oneline | cut -d ' ' -f1`
|
||||
|
||||
cat > $FILE <<EOF
|
||||
/* See build-aux/versionify */
|
||||
#include "dl_fldigi/version.h"
|
||||
|
||||
namespace dl_fldigi {
|
||||
|
||||
const char *git_commit = "$COMMIT";
|
||||
const char *git_short_commit = "$SHORT_COMMIT";
|
||||
|
||||
}
|
||||
EOF
|
||||
|
||||
echo "$COMMIT $SHORT_COMMIT >> $FILE"
|
|
@ -280,6 +280,7 @@ dl_fldigi_SOURCES += \
|
|||
include/Fl_Text_Buffer_mod.H \
|
||||
include/Fl_Text_Display_mod.H \
|
||||
include/Fl_Text_Editor_mod.H \
|
||||
include/Fl_Tile_Check.h \
|
||||
include/Panel.h \
|
||||
include/FreqControl.h \
|
||||
include/analysis.h \
|
||||
|
@ -410,6 +411,7 @@ dl_fldigi_SOURCES += \
|
|||
include/psk_browser.h \
|
||||
include/dl_fldigi/dl_fldigi.h \
|
||||
include/dl_fldigi/gps.h \
|
||||
include/dl_fldigi/version.h \
|
||||
include/habitat/CouchDB.h \
|
||||
include/habitat/UploaderThread.h \
|
||||
include/habitat/Uploader.h \
|
||||
|
@ -552,7 +554,8 @@ dl_fldigi_SOURCES += \
|
|||
habitat/UploaderThread.cxx \
|
||||
habitat/Uploader.cxx \
|
||||
dl_fldigi/dl_fldigi.cxx \
|
||||
dl_fldigi/gps.cxx
|
||||
dl_fldigi/gps.cxx \
|
||||
dl_fldigi/version.cxx
|
||||
|
||||
# Sources that are part of the distribution but are not compiled directly
|
||||
EXTRA_dl_fldigi_SOURCES += \
|
||||
|
@ -600,7 +603,14 @@ EXTRA_dl_fldigi_SOURCES += \
|
|||
widgets/Fl_Text_Display_mod_1_1.cxx \
|
||||
widgets/Fl_Text_Display_mod_1_3.cxx \
|
||||
widgets/Fl_Text_Editor_mod_1_1.cxx \
|
||||
widgets/Fl_Text_Editor_mod_1_3.cxx
|
||||
widgets/Fl_Text_Editor_mod_1_3.cxx \
|
||||
habitat/CouchDB.h \
|
||||
habitat/UploaderThread.h \
|
||||
habitat/Uploader.h \
|
||||
habitat/Extractor.h \
|
||||
habitat/UKHASExtractor.h \
|
||||
habitat/EZ.h
|
||||
|
||||
|
||||
|
||||
flarq_SOURCES += \
|
||||
|
@ -665,7 +675,7 @@ EXTRA_DIST = \
|
|||
$(srcdir)/../scripts/tests/config-h.sh \
|
||||
$(srcdir)/../data/fldigi-psk.png \
|
||||
$(srcdir)/../data/fldigi-rtty.png \
|
||||
$(srcdir)/../data/fldigi.xpm \
|
||||
$(srcdir)/../data/dl-fldigi.xpm \
|
||||
$(srcdir)/../data/fldigi.desktop \
|
||||
$(srcdir)/../data/dl-fldigi.desktop \
|
||||
$(srcdir)/../data/dl-fldigi-hab.desktop \
|
||||
|
@ -678,3 +688,10 @@ EXTRA_DIST = \
|
|||
$(srcdir)/../data/win32/flarq.ico \
|
||||
$(FLDIGI_FL_SRC) \
|
||||
$(FLARQ_FL_SRC)
|
||||
|
||||
dl_fldigi/version.cxx :
|
||||
test -f $(srcdir)/../build-aux/versionify && $(srcdir)/../build-aux/versionify || true
|
||||
|
||||
dist-hook : dl_fldigi/version.cxx
|
||||
|
||||
.PHONY : dl_fldigi/version.cxx
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
#include <Fl/Fl.H>
|
||||
#include "habitat/UKHASExtractor.h"
|
||||
#include "habitat/EZ.h"
|
||||
#include "dl_fldigi/version.h"
|
||||
#include "configuration.h"
|
||||
#include "debug.h"
|
||||
#include "fl_digi.h"
|
||||
|
@ -27,9 +28,6 @@ namespace dl_fldigi {
|
|||
/* How does online/offline work? if online() is false, uthr->settings() will
|
||||
* reset the UploaderThread, leaving it unintialised */
|
||||
|
||||
/* TODO: HABITAT-LATER maybe upload the git commit when compiled as the
|
||||
* 'version' */
|
||||
|
||||
DExtractorManager *extrmgr;
|
||||
DUploaderThread *uthr;
|
||||
enum location_mode new_location_mode;
|
||||
|
@ -1337,6 +1335,7 @@ void DUploaderThread::listener_info()
|
|||
info_add(data, "location", progdefaults.myQth);
|
||||
info_add(data, "radio", progdefaults.myRadio);
|
||||
info_add(data, "antenna", progdefaults.myAntenna);
|
||||
data["dl_fldigi"] = git_short_commit;
|
||||
|
||||
if (!data.size())
|
||||
{
|
||||
|
|
|
@ -1244,11 +1244,12 @@
|
|||
\
|
||||
/* dl-fldigi network config stuff */ \
|
||||
ELEM_(std::string, habitat_uri, "HABITAT_URI", \
|
||||
"habitat CouchDB URI", "http://habhub.org") \
|
||||
"habitat CouchDB URI", "http://habitat.habhub.org") \
|
||||
/* TODO HABITAT LATER: change the url above to http://habhub.org when setup */ \
|
||||
ELEM_(std::string, habitat_db, "HABITAT_DB", \
|
||||
"habitat CouchDB databse", "habitat") \
|
||||
\
|
||||
/* TODO HABITAT: swap to habitat! Give SSDV the UploaderThread object */ \
|
||||
/* TODO HABITAT LATER: swap to habitat! Give SSDV the UploaderThread object */ \
|
||||
ELEM_(std::string, ssdv_packet_url, "SSDV_BLOCK_URL", \
|
||||
"Remote URL", "http://www.sanslogic.co.uk/ssdv/data.php") \
|
||||
ELEM_(std::string, ssdv_block_user, "SSDV_BLOCK_USER", \
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
#ifndef DL_FLDIGI_VERSION_H
|
||||
#define DL_FLDIGI_VERSION_H
|
||||
|
||||
namespace dl_fldigi {
|
||||
|
||||
extern const char *git_commit;
|
||||
extern const char *git_short_commit;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
Ładowanie…
Reference in New Issue