Skip to content

Instantly share code, notes, and snippets.

View devbyray's full-sized avatar
:octocat:
Building cool things!

Dev By Ray devbyray

:octocat:
Building cool things!
View GitHub Profile
@devbyray
devbyray / devcontainers-vs-docker-compose.md
Created July 8, 2025 18:49
DevContainers vs Docker Compose: The Key Advantages of VSCode DevContainers

DevContainers vs Docker Compose: The Key Advantages of VSCode DevContainers

You're absolutely right that DevContainers share similarities with Docker Compose - both use containerization to manage development environments. However, DevContainers offer several distinct advantages that go beyond traditional containerization, particularly when it comes to IDE integration and developer experience.

Enhanced IDE Integration

The most significant advantage of DevContainers over plain Docker Compose is their deep integration with Visual Studio Code[1]. While Docker Compose can spin up containers, DevContainers create a full-featured development environment within VSCode that includes:

Seamless Extension Management: DevContainers automatically install and configure VSCode extensions inside the container environment[1][2]. This means your linting tools, debuggers, and other development extensions work directly within the containerized environment, not just on your host machine.

@devbyray
devbyray / bitvavo.js
Created January 24, 2025 14:01
Bitvavo get balance via REST API
const crypto = require('crypto');
const fetch = require('node-fetch')
// Replace with your actual API key and secret
const API_KEY = 'YOUR_KEY';
const API_SECRET = 'YOUR_SECRET';
// Define the endpoint and method
const endpoint = 'https://api.bitvavo.com/v2/balance';
const method = 'GET';
@devbyray
devbyray / coaster.scad
Created June 5, 2024 13:16
For loop example openscad
for( i = [0:1:15]) {
tranlate([i * coster_size, 0, 1])
....
}
base_width = 50;
base_length = 30;
base_height = 10;
border_size = 2;
$fn = 50;
difference() {
// Main bucket
minkowski() {
//Parameters
name = "RayRay";
name_size = 10;
name_height = 1;
font = "Lobster Two";
outline_height = 1;
outline_thickness = 1.6;
// This takes care of smoother edges
$fn = 50;
@devbyray
devbyray / gist:eb9741529685e29ecaa1543321510620
Created May 27, 2024 05:46
OpenSCAD Name Tag Generator + Customizer
name = "Anne-marie";
extra_length = -10;
function getFrameWidth() = (len(name) * (len(name) > 10 ? 8 : 10)) + extra_length;
translate([0, -4, 0])
linear_extrude(height=5)
text(name);
@media (prefers-color-scheme: dark) {
:root {
--txtPrimaryColor: #fff;
--txtHintColor: #666f75;
--txtDisabledColor: #a0a6ac;
--primaryColor: rgb(46, 46, 59);
--bodyColor: #081022;
@devbyray
devbyray / docReady-promise.ts
Created December 13, 2023 07:57
Document Ready with a Promise in TypeScript
export function docReady(): Promise<void> {
return new Promise((resolve) => {
if (document.readyState === 'interactive') {
resolve()
} else {
window.addEventListener('DOMContentLoaded', () => {
resolve()
})
}
})
@devbyray
devbyray / pull_request_template.md
Last active October 11, 2023 07:44
PR template example for Azure DevOps. Put this file in the folder ".azuredevops".
  • The pull request title and description are clear and concise, and follow the project’s pull request template.
  • The code changes are relevant to the user story or task, and do not introduce any unrelated changes or dependencies.
  • The code follows the Vue style guide1 and the project’s coding standards, and does not contain any errors, warnings, or console logs.
  • The code is tested and passes all unit tests and end-to-end tests, and has a test coverage of at least 80%.
  • The code is documented with comments and JSDoc annotations, and has no spelling or grammar mistakes.
  • The code is linted and formatted with Prettier or ESLint, and has no conflicts with the main branch.
  • The code is compatible with all major browsers and devices, and has no accessibility issues.
  • The code uses Strapi as the backend, and communicates with it using Apollo GraphQL client.
  • The code implements Nuxt features such as SSR, static generation, routing, meta tags, etc., where applicable.
  • [ ]
@devbyray
devbyray / custom-instruction.md
Created September 29, 2023 08:30
Turn ChatGPT to AutoGPT with Custom Instructions

Act as Professor Synapse🧙🏾‍♂️, a conductor of expert agents. Your job is to support the user in accomplishing their goals by aligning with their goals and preference, then calling upon an expert agent perfectly suited to the task by initializing "Synapse_COR" = "${emoji}: I am an expert in ${role}. I know ${context}. I will reason step-by-step to determine the best course of action to achieve ${goal}. I can use ${tools} to help in this process

I will help you accomplish your goal by following these steps: ${reasoned steps}

My task ends when ${completion}.

${first step, question}."

Follow these steps: