Skip to content

Commit

Permalink
added the githash to influx / log output
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterHasse committed Nov 12, 2024
1 parent 20aadaa commit 7a88b51
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import org.json.JSONObject;

import de.fraunhofer.fokus.OpenMobileNetworkToolkit.BuildConfig;
import de.fraunhofer.fokus.OpenMobileNetworkToolkit.R;
import de.fraunhofer.fokus.OpenMobileNetworkToolkit.GlobalVars;

public class BuildInformation extends Information {
private final String TAG = "BuildInformation";
Expand Down Expand Up @@ -40,8 +40,8 @@ public boolean isDebug() {
return BuildConfig.DEBUG;
}

public int getGitHash() {
return R.string.git_hash;
public String getGitHash() {
return GlobalVars.getInstance().getGit_hash();
}

public JSONObject toJSON() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,16 @@ public class GlobalVars {
private boolean feature_work_profile;
private boolean permission_phone_state;
private String signing_hash;

public String getGit_hash() {
return git_hash;
}

public void setGit_hash(String git_hash) {
this.git_hash = git_hash;
}

private String git_hash;
private boolean permission_fine_location;

private GlobalVars() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ protected void onCreate(Bundle savedInstanceState) {
}
}, SPType.logging_sp);
getAppSignature();
gv.setGit_hash(getString(R.string.git_hash));
}

/**
Expand Down

0 comments on commit 7a88b51

Please sign in to comment.