Skip to content

Instantly share code, notes, and snippets.

View bemijonathan's full-sized avatar
🎓
Learning

Jonathan Atiene bemijonathan

🎓
Learning
View GitHub Profile
import { buildSchema, graphql } from "graphql";
// Construct a schema, using GraphQL schema language
let graphqlSchema = buildSchema(`
type Query {
recipes: [Recipe]
recipes_by_pk(id: Int!): Recipe
}
type Recipe {
id: ID!
@bemijonathan
bemijonathan / node_nginx_ssl.md
Created August 22, 2020 14:52 — forked from bradtraversy/node_nginx_ssl.md
Node app deploy with nginx & SSL

Node.js Deployment

Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt

1. Sign up for Digital Ocean

If you use the referal link below, you get $10 free (1 or 2 months) https://m.do.co/c/5424d440c63a

2. Create a droplet and log in via ssh

I will be using the root user, but would suggest creating a new user

@bemijonathan
bemijonathan / docker-help.md
Created August 23, 2020 03:45 — forked from bradtraversy/docker-help.md
Docker Commands, Help & Tips

Docker Commands, Help & Tips

Show commands & management commands

$ docker

Docker version info

@bemijonathan
bemijonathan / GitHub curl.sh
Created February 27, 2021 09:53 — forked from Integralist/GitHub curl.sh
Download a single file from a private GitHub repo. You'll need an access token as described in this GitHub Help article: https://help.github.com/articles/creating-an-access-token-for-command-line-use
curl --header 'Authorization: token INSERTACCESSTOKENHERE' \
--header 'Accept: application/vnd.github.v3.raw' \
--remote-name \
--location https://api.github.com/repos/owner/repo/contents/path
# Example...
TOKEN="INSERTACCESSTOKENHERE"
OWNER="BBC-News"
REPO="responsive-news"
"use strict"
const fs = require("fs");
const assert = require("assert");
const inputValues = []
//get all values from the file input;
fs.readFileSync("input.txt", "utf-8")
.split('\n\n')
@bemijonathan
bemijonathan / doc.md
Last active September 19, 2023 11:18
Enhancing a coderabbit reviews with file path prompts

Introduction

This documentation describes how to add specific code review instructions to match specific glob files path in your project, This feature allows developers to set custom instructions for code review based on file paths, thus enhancing the effectiveness of the code reviews from coderabbit.

Overview

Adding file path prompts allows developers to specify custom instructions for different parts of the codebase. For example, you may want to enforce the use of standard JS format for reviewing TypeScript files in a specific directory: or the Google Style Guide for your tsx files in another directory, specifying these instructions ultimately increase the accuracy the reviews

@bemijonathan
bemijonathan / gist:8bc892b1e12954e45a906e0704cff86d
Last active May 15, 2025 13:58
Customizing your code review experience with coderabbit.yml

Customizing CI Code Review with CodeRabbit

Overview

CodeRabbit allows developers to customize your ai review review process by defining the settings in a coderabbit.yml file. This document provides a brief overview of the keys used in the coderabbit.yml file and their functions. please note that the default parameters in the schema will be used if values are not provided.

Sample coderabbit.yml File

# Crazyflie autonomous control, [email protected]
from controller import Receiver, Emitter
from controller import Robot
from crazyflie_flyingcontroller import CrazyflieFlyingController
from controller import Keyboard
import math
import numpy as np
class BaseAgent():
def __init__(self, name, role, provider_config, tools):
self.name = name
self.role = role
self.memory = []
self.provider = provider_config
self.tools = tools
async def use_tool(self, tool_name, params: Dict[str, Any])
"""Execute a tool with given parameters"""