pip install plantuml
pip install py2puml
pip install mypymypy .| import datetime | |
| import json | |
| import os | |
| import requests | |
| WEBHOOK_URL: str = os.getenv("WEBHOOK_URL") | |
| SLACK_CHANNEL: str = os.getenv("SLACK_CHANNEL", "#devops-alarms") | |
| SLACK_USERNAME: str = os.getenv("SLACK_USERNAME", "aws-alarm-bot") |
| ##### https://flake8.pycqa.org/en/latest/user/configuration.html | |
| [flake8] | |
| ignore = | |
| # D100: Missing docstring at top of file | |
| D100, | |
| # D104: Missing docstring in __init__.py | |
| D104, | |
| # D401: Docstring first line should be imperative | |
| D401, | |
| # D101 Missing docstring in public class |
| #!/usr/bin/env sh | |
| ######## Dependencies ########################################################## | |
| # https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2.html | |
| # https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-sso.html | |
| # https://docs.aws.amazon.com/systems-manager/latest/userguide/session-manager-working-with-install-plugin.html | |
| # | |
| ######## Usage ################################################################# | |
| # | |
| # Install Proxy Command | |
| # - Move this script to ~/.ssh/aws-proxy.sh |
| YOUR_FLASH_DRIVE=$(/bin/ls /dev/disk/by-id/usb-*\:0) | |
| sudo fdisk $YOUR_FLASH_DRIVE | |
| # o <CR> n <CR> p <CR> <CR> <CR> <CR> w <CR> | |
| sudo mkfs.fat $YOUR_FLASH_DRIVE-part1 | |
| sudo chmod -R ugo+rw $YOUR_FLASH_DRIVE | |
| eject $YOUR_FLASH_DRIVE |
| /* | |
| http://www.graphviz.org/doc/info/lang.html | |
| */ | |
| digraph G { | |
| size ="10,10"; // Comment | |
| ranksep=.75; | |
| main [label="MAIN\n<AWS::IAM::Role>"]; | |
| main -> parse -> execute; | |
| main -> init; | |
| main -> cleanup; |
| # Some default values | |
| DEFAULTPOMODOROS="6" | |
| WORKTIME="1500" # in seconds (25 minutes) | |
| SHORTREST="300" # in seconds (5 minutes) | |
| LONGREST="1200" # in seconds (20 minutes) | |
| LONGBREAK="4" # number of pomodoros before a long break | |
| UPDATEINTERVAL="60" # in seconds | |
| # Function to provide the updates for the progress bar | |
| # Parameter 1 = time in seconds |
| <?xml version="1.0" encoding="UTF-16"?> | |
| <Task version="1.2" xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task"> | |
| <RegistrationInfo> | |
| <Date>2021-09-26T17:04:07.1303814</Date> | |
| <Author>jbrinkma</Author> | |
| <URI>\Daily Timesheet</URI> | |
| </RegistrationInfo> | |
| <Triggers> | |
| <CalendarTrigger> | |
| <StartBoundary>2021-09-26T16:45:00</StartBoundary> |
| import React from 'react'; | |
| // https://redux.js.org/recipes/writing-tests | |
| import { render, fireEvent, screen } from '../../../test-utils.js'; | |
| import MyRow from './MyRow.js'; | |
| describe('test for MyRow', () => { | |
| it('renders a row allowing delete', () => { | |
| const { getByText, getByTitle } = render( | |
| <MyRow key={0} canEdit={true} id={0} />, |
| create [or replace] function foo_func(param_list) | |
| [ RETURNS rettype | |
| | RETURNS TABLE ( column_name column_type [, ...] ) ] | |
| language plpgsql | |
| as | |
| $BODY$ | |
| <<first_block>> -- declare ... begin ... end | |
| declare | |
| -- variable declaration | |
| film_count integer := 0; |