Skip to content

Instantly share code, notes, and snippets.

View AhmadS7's full-sized avatar
🪢
-> sirius

Ahmad S. AhmadS7

🪢
-> sirius
View GitHub Profile
@AhmadS7
AhmadS7 / settings.json
Created June 23, 2024 12:21 — forked from adibhanna/settings.json
zed settings
{
"theme": "Gruvbox Dark Hard",
"base_keymap": "VSCode",
"buffer_font_family": "BerkeleyMono Nerd Font",
"buffer_font_size": 15,
"vim_mode": true,
"relative_line_numbers": true,
"cursor_blink": false,
"scrollbar": {
"show": "never"
@AhmadS7
AhmadS7 / keybindings.json
Created January 19, 2024 12:13
My VSCode settings.json and keybindings.json files
// Place your key bindings in this file to override the defaults
[
{
"key": "alt+d",
"command": "workbench.action.toggleActivityBarVisibility",
"when": ""
},
{
"key": "ctrl+n",
"command": "workbench.action.terminal.toggleTerminal",
@AhmadS7
AhmadS7 / .prettierrc
Created January 19, 2024 02:57
prettier settings
{
"useTabs": true,
"singleQuote": true,
"trailingComma": "none",
"printWidth": 100,
"overrides": [
{
"files": ["*.js"],
"options": {
"bracketSameLine": false
@AhmadS7
AhmadS7 / chat-client.c
Created January 14, 2024 10:05
Minimalist Chat Server and Client in C - just for fun, not suitable for production
#include <sys/socket.h>
#include <stdio.h>
#include <arpa/inet.h>
#include <poll.h>
#include <unistd.h>
int main() {
int sockfd = socket(AF_INET, SOCK_STREAM, 0);
struct sockaddr_in address = {
@AhmadS7
AhmadS7 / terminal-commands.md
Created January 1, 2024 23:01 — forked from bradtraversy/terminal-commands.md
Common Terminal Commands

Common Terminal Commands

Key Commands & Navigation

Before we look at some common commands, I just want to note a few keyboard commands that are very helpful:

  • Up Arrow: Will show your last command
  • Down Arrow: Will show your next command
  • Tab: Will auto-complete your command
  • Ctrl + L: Will clear the screen
@AhmadS7
AhmadS7 / terminal-commands.md
Created January 1, 2024 23:01 — forked from bradtraversy/terminal-commands.md
Common Terminal Commands

Common Terminal Commands

Key Commands & Navigation

Before we look at some common commands, I just want to note a few keyboard commands that are very helpful:

  • Up Arrow: Will show your last command
  • Down Arrow: Will show your next command
  • Tab: Will auto-complete your command
  • Ctrl + L: Will clear the screen
@AhmadS7
AhmadS7 / keybindings.json
Created August 26, 2023 04:48
VSCode + VIM keybindings
// Place your key bindings in this file to override the defaults
[
{
"command": "projectManager.listGitProjects#sideBarGit",
"key": "alt+o"
},
{
"command": "expand_region",
"key": "ctrl+=",
"when": "editorTextFocus"
@AhmadS7
AhmadS7 / .prettierrc.js
Created July 23, 2023 07:29
Prettier settings for any project
module.exports = {
arrowParens: 'avoid',
bracketSpacing: true,
jsxBracketSameLine: false,
jsxSingleQuote: false,
printWidth: 80,
quoteProps: 'as-needed',
rangeStart: 0,
rangeEnd: Infinity,
semi: true,
@AhmadS7
AhmadS7 / mongodb_cheat_sheet.md
Created December 4, 2022 00:41 — forked from bradtraversy/mongodb_cheat_sheet.md
MongoDB Cheat Sheet

MongoDB Cheat Sheet

Show All Databases

show dbs

Show Current Database

@AhmadS7
AhmadS7 / prettier.config.js
Created May 17, 2022 08:19
Prettier Config File for JS
const options = {
arrowParens: 'avoid',
singleQuote: true,
bracketSpacing: true,
endOfline: 'lf',
semi: false,
tabWidth: 2,
trailingComma: 'none'
}