Skip to content

Instantly share code, notes, and snippets.

View 094459's full-sized avatar

Ricardo Sueiras 094459

View GitHub Profile
@094459
094459 / gist:63a5526e5d909613ba0ca36dab97a658
Created March 22, 2025 11:03
Amazon Q CLI zip verify
-----BEGIN PGP PUBLIC KEY BLOCK-----
mDMEZig60RYJKwYBBAHaRw8BAQdAy/+G05U5/EOA72WlcD4WkYn5SInri8pc4Z6D
BKNNGOm0JEFtYXpvbiBRIENMSSBUZWFtIDxxLWNsaUBhbWF6b24uY29tPoiZBBMW
CgBBFiEEmvYEF+gnQskUPgPsUNx6jcJMVmcFAmYoOtECGwMFCQPCZwAFCwkIBwIC
IgIGFQoJCAsCBBYCAwECHgcCF4AACgkQUNx6jcJMVmef5QD/QWWEGG/cOnbDnp68
SJXuFkwiNwlH2rPw9ZRIQMnfAS0A/0V6ZsGB4kOylBfc7CNfzRFGtovdBBgHqA6P
zQ/PNscGuDgEZig60RIKKwYBBAGXVQEFAQEHQC4qleONMBCq3+wJwbZSr0vbuRba
D1xr4wUPn4Avn4AnAwEIB4h+BBgWCgAmFiEEmvYEF+gnQskUPgPsUNx6jcJMVmcF
AmYoOtECGwwFCQPCZwAACgkQUNx6jcJMVmchMgEA6l3RveCM0YHAGQaSFMkguoAo
@094459
094459 / gist:bf583505f11c2e1a1932f1db6f5e0610
Created March 8, 2025 19:16
Scaffold document to help shape LLM output
When creating Python code, use the following guidance
- Use Flask as the web framework
- Follow Flask's application factory pattern
- Use Pydantic for data validation
- Use environment variables for configuration
- Implement Flask-SQLAlchemy for database operations
- Use Swagger to provide an interactive API UI
Use the following project structure
@094459
094459 / fact-checker.yaml
Created March 8, 2025 19:15
Data model for a simple fact checking application
tables:
users:
columns:
id:
type: integer
primary_key: true
autoincrement: true
email:
type: text
unique: true
@094459
094459 / gist:1d2e285bb97154a3a2bff6f727ae53b3
Created November 21, 2024 14:06
Bounce more than 8 sprites across the screen - C64 6402 assembler
// Attribution - based from code here - https://raw.githubusercontent.com/zendar/spritemultiplexer/refs/heads/master/multi.asm
// Add these new constants for screen boundaries and initial velocities
.const SCREEN_LEFT = 24
.const SCREEN_RIGHT = 344
.const SCREEN_TOP = 50
.const SCREEN_BOTTOM = 229
.const INITIAL_VEL_X = 1
.const INITIAL_VEL_Y = 2
.const PADDING = 4
@094459
094459 / gist:13c06a50c4225d077ec9ed17161206e4
Created November 21, 2024 12:42
Sprite multiplexor for C64
// Attribution - based from code here - https://raw.githubusercontent.com/zendar/spritemultiplexer/refs/heads/master/multi.asm
// Constants
.const PADDING = 4
.const MAX_SPRITES = 22 // 16 makes a great circle
.const TEMP1 = $FB
.const TEMP2 = $FC
.const SpriteIndex = $FD
.const VicSpriteIndex = $FE
// Use BasicUpstart2 to create proper BASIC startup
@094459
094459 / gist:e68634386df4f5fb7f6775d339672771
Created July 5, 2024 08:48
This is a quick lambda function that uses environment variables to hold your GITHUB keys, to them scrape the usage statistics and store them in CloudWatch logs. You should configure this to run only once a day, and configure the Lambda execution configuration to run the appropriate amount of time. Once in CloudWatch logs, you can use CloudWatch …
# forked from https://github.com/AnthonyBloomer/github-traffic-insights
# changed so that it outputs just to cloudwatch
# use Cloudwatch Insights to track GitHub Traffic
import json
import os
from urllib import request
def record_custom_event(event):
@094459
094459 / vscode-server.yaml
Created May 17, 2024 14:15
This is a Cloudformation template that will deploy a VSCode server running on an EC2 instance with Python, Node, Java, .NET, Rust installed, as well as Amazon Q Developer. Ready to go.
Description: Create a VSCode code-server instance with an Amazon CloudFront distribution.
Parameters:
EC2KeyPair:
Type: AWS::EC2::KeyPair::KeyName
Description: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/create-key-pairs.html
Default: ws-default-keypair
InstanceVolumeSize:
Type: Number
Description: The volume size in GB
@094459
094459 / gist:3eba3e5f4fb1ccaef1cb12044412f90b
Created September 4, 2023 15:44
Quick script to enable Python 3.10.11 on AWS Cloud9
#!/bin/sh
# Thanks to https://stackoverflow.com/questions/71954694/pyenv-on-amazon-linux-fails-to-build-due-to-openssl
# and https://gist.github.com/djohnkang/062e1b5c37df7d4d5b4e503315481282
# Save this as a bash script in your AWS Cloud9 environment, and then run it. After it runs, you should now have Python 3.10.11 available
sudo yum remove openssl-devel.x86_64 -y
sudo yum autoremove -y
sudo yum install gcc zlib-devel bzip2 bzip2-devel readline readline-devel sqlite sqlite-devel opensll openssl11-devel libffi-devel xz-devel -y
# sudo yum groupinstall "Development Tools" -y && sudo yum install -y zlib-devel bzip2 bzip2-devel readline-devel sqlite sqlite-devel tk-devel libffi-devel xz-devel

Keybase proof

I hereby claim:

To claim this, I am signing this object:

Verifying that +094459 is my blockchain ID. https://onename.com/094459