This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
- Helper module for ui app actionbar | |
- Author: alexrjs | |
- License: Unlicense | |
""" | |
# imports | |
from flet import Container, Row, Text, UserControl | |
from flet import colors |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"id": "6dd9c5de00783d54", | |
"type": "tab", | |
"label": "Rest API Sample", | |
"disabled": false, | |
"info": "", | |
"env": [] | |
}, | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM node:current-alpine | |
RUN npm install -g json-server | |
COPY ./plural.js /usr/local/lib/node_modules/json-server/lib/server/router/plural.js | |
COPY ./defaults.js /usr/local/lib/node_modules/json-server/lib/server/defaults.js | |
HEALTHCHECK --interval=120s --timeout=15s --start-period=30s CMD wget -S --spider http://localhost:8080/ | |
EXPOSE 80 | |
WORKDIR /data | |
VOLUME /data | |
ENTRYPOINT ["json-server"] | |
CMD ["--host", "0.0.0.0", "--port", "80", "db.json"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import random | |
class Rotor: | |
""" | |
Models a 'rotor' in an Enigma machine | |
Rotor("BCDA", 1) means that A->B, B->C, C->D, D->A and the rotor has been | |
rotated once from ABCD (the clear text character 'B' is facing the user) |