fixed ci/cd
added config.json
This commit is contained in:
parent
cf853ced14
commit
4417df86a2
@ -24,14 +24,14 @@ jobs:
|
||||
- name: Install dependencies
|
||||
run: npm install
|
||||
|
||||
- name: Build app
|
||||
run: npm run build
|
||||
|
||||
- name: Export version from metadata.json
|
||||
name: Export version from metadata.json
|
||||
run: |
|
||||
VERSION=$(jq -r '"\(.buildMajor).\(.buildMinor).\(.buildRevision)-\(.buildTag)"' src/metadata.json)
|
||||
echo "VERSION=$VERSION" >> $GITHUB_ENV
|
||||
|
||||
- name: Build app
|
||||
run: npm run build
|
||||
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
|
||||
@ -23,11 +23,11 @@ import AccountCircleIcon from '@mui/icons-material/AccountCircleOutlined';
|
||||
import { ThemeProvider } from '@mui/material/styles';
|
||||
import theme from '../theme';
|
||||
import deleteToken from '../core/deleteToken';
|
||||
import config from '../config.json';
|
||||
|
||||
const drawerWidth = 240;
|
||||
|
||||
export default function SettingsMain() {
|
||||
const [open, setOpen] = useState(false);
|
||||
const [anchorEl, setAnchorEl] = useState(null);
|
||||
const openMenu = Boolean(anchorEl);
|
||||
|
||||
@ -112,10 +112,12 @@ export default function SettingsMain() {
|
||||
<PeopleIcon sx={{ marginRight: 2, color: '#FFFFFF' }}/>
|
||||
<ListItemText primary="Access lists" sx={{ color: '#FFFFFF' }} />
|
||||
</ListItem>
|
||||
<ListItem button key="Debug">
|
||||
<BarChartIcon sx={{ marginRight: 2, color: '#FFFFFF' }}/>
|
||||
<ListItemText primary="Debug" sx={{ color: '#FFFFFF' }} />
|
||||
</ListItem>
|
||||
{config.developerMode && (
|
||||
<ListItem button key="Debug">
|
||||
<BarChartIcon sx={{ marginRight: 2, color: '#FFFFFF' }}/>
|
||||
<ListItemText primary="Debug" sx={{ color: '#FFFFFF' }} />
|
||||
</ListItem>
|
||||
)}
|
||||
|
||||
</List>
|
||||
</Drawer>
|
||||
|
||||
5
src/config.json
Normal file
5
src/config.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"developerMode": false,
|
||||
"backendUrl": "https://api.example.com"
|
||||
|
||||
}
|
||||
@ -1 +1 @@
|
||||
{"buildMajor":1,"buildMinor":0,"buildRevision":10,"buildTag":"DEV"}
|
||||
{"buildMajor":1,"buildMinor":0,"buildRevision":11,"buildTag":"DEV"}
|
||||
Loading…
Reference in New Issue
Block a user