Skip to content

Commit

Permalink
Different backup folder depending on build flavor
Browse files Browse the repository at this point in the history
  • Loading branch information
federicoiosue committed Feb 20, 2017
1 parent 6e3e5f3 commit 35740cc
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
/*
* Copyright (C) 2015 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package it.feio.android.omninotes.utils;

public interface Constants extends ConstantsBase {

String TAG = "Omni Notes FOSS";
String EXTERNAL_STORAGE_FOLDER = "Omni Notes Foss";
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@
*/
package it.feio.android.omninotes.utils;

public interface Constants {
public interface ConstantsBase {

String TAG = "Omni Notes";
String DATABASE_NAME = "omni-notes";
String PACKAGE = "it.feio.android.omninotes";
String PREFS_NAME = PACKAGE + "_preferences";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ public static File getCacheDir(Context mContext) {


public static File getExternalStoragePublicDir() {
File dir = new File(Environment.getExternalStorageDirectory() + File.separator + Constants.TAG + File
File dir = new File(Environment.getExternalStorageDirectory() + File.separator + Constants.EXTERNAL_STORAGE_FOLDER + File
.separator);
if (!dir.exists())
dir.mkdirs();
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
/*
* Copyright (C) 2017 Federico Iosue ([email protected])
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundatibehaon, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package it.feio.android.omninotes.utils;

public interface Constants extends ConstantsBase {

String TAG = "Omni Notes";
String EXTERNAL_STORAGE_FOLDER = "Omni Notes";
}

0 comments on commit 35740cc

Please sign in to comment.