This file contains hidden or 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
| #!/usr/bin/env bash | |
| # -*- coding: utf-8 -*- | |
| # Create log directory if it doesn't exist | |
| mkdir -p "$HOME/.local/logs" | |
| # users environment is not preserved, add necessary env vars | |
| # export AWS_PROFILE="Your-non-default-profile" | |
| # use different browser so it does not interupt my default browser use | |
| export BROWSER=/Applications/Safari.app/Contents/MacOS/Safari | |
| LOG_FILE="$HOME/.local/logs/awsrefresh.log" |
This file contains hidden or 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
| # Folder paths are | |
| # project-root/ | |
| # ├── notebooks/ | |
| # │ └── my_notebook.ipynb | |
| # └── sami/ | |
| # ├── __init__.py # (recommended) | |
| # └── my_module.py | |
| import sys | |
| import os |
This file contains hidden or 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
| # Project Policy | |
| This policy provides a single, authoritative, and machine-readable source of truth for AI coding agents and humans, ensuring that all work is governed by clear, unambiguous rules and workflows. It aims to eliminate ambiguity, reduce supervision needs, and facilitate automation while maintaining accountability and compliance with best practices. | |
| # 1. Introduction | |
| > Rationale: Sets the context, actors, and compliance requirements for the policy, ensuring all participants understand their roles and responsibilities. | |
| ## 1.1 Actors |
This file contains hidden or 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
| def func(x=[]): | |
| x.append(1) | |
| return x | |
| print(func()) | |
| print(func()) | |
| print(func([2])) |
This file contains hidden or 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
| // This script reqires a local server to be running at localhost:3000 | |
| // to handle the cryptographic signature. | |
| // store your signing key in your enviroment | |
| const signingKey = pm.environment.get("signing_key"); | |
| // javascript Date.now() returns unix timestamp in ms, convert to s | |
| const timestamp = Math.floor(Date.now() / 1000) | |
| const method = pm.request.method.toString(); | |
| // Postman does not substitute URL parameters before running this script |
This file contains hidden or 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
| // The example at https://blog.postman.com/adding-external-libraries-in-postman/ | |
| // was failing for me due to exports, for this particular library stripping the last 3 lines loaded the library successfully. | |
| // NOTE: this particular library does not work in Postman due to missing dependencies from node/browser | |
| function removeLastLines(text, num) { | |
| // Split the text into lines | |
| const lines = text.split('\n'); | |
| // Remove the last two lines | |
| lines.splice(-num); |
This file contains hidden or 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
| """ Place the resulting output into the style of a draw.io shape. | |
| Edit Style -> paste output at end. | |
| """ | |
| import numpy as np | |
| # generate connection points for draw.io shapes | |
| hnum=16 # sections along the horizontal | |
| vnum=4 # sections along the vertical | |
| precision=4 | |
| points=[] |
This file contains hidden or 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 pandas as pd | |
| import numpy as np | |
| # tax tables for 2026 from page 10 of https://www.irs.gov/pub/irs-drop/rp-25-32.pdf | |
| # married filing jointly | |
| over = [ | |
| 0, | |
| 24800, | |
| 100800, | |
| 211400, |
This file contains hidden or 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
| ARG UNAME=antonios | |
| ARG UID=1000 | |
| ARG GID=1000 | |
| RUN groupadd -g $GID -o $UNAME | |
| RUN useradd -m -u $UID -g $GID -o -s /bin/bash $UNAME | |
| RUN usermod -aG sudo $UNAME | |
| USER $UNAME |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
NewerOlder