A Pen by Fernando Celmer on CodePen.
This file contains 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
#!/bin/bash | |
read -p 'Email: ' email | |
ssh-keygen -t ed25519 -C $email | |
eval "$(ssh-agent -s)" | |
read -p 'SSH File Name: ' configfile | |
read -p 'Host Name: ' confighost | |
read -p 'Host Domain: ' configdomain |
This file contains 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
{ | |
"Debug Console Python": { | |
"prefix": "frompdb", | |
"body": [ | |
"from pdb import set_trace; set_trace()" | |
], | |
"description": "Debug PDB Python" | |
} | |
} |
This file contains 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
FROM archlinux:base-devel | |
RUN useradd -m build && \ | |
pacman -Syu --noconfirm && \ | |
pacman -Sy --noconfirm git && \ | |
echo "build ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/build | |
USER build | |
WORKDIR /home/build |
This file contains 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 os | |
pattern = [ | |
"⚙️ FEATURE", | |
"📝 PEP8", | |
"📌 ISSUE", | |
"🪲 BUG", | |
"📘 DOCS", | |
"📦 PyPI", | |
"❤️️ TEST", |
This file contains 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 scrapy | |
class BlogSpider(scrapy.Spider): | |
name = 'blogspider' | |
start_urls = ['https://www.zyte.com/blog/'] | |
def parse(self, response): | |
for title in response.css('.oxy-post-title'): | |
yield {'title': title.css('::text').get()} |
This file contains 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 pyramid(scale: int): | |
node = [] | |
for index in range(1, scale + 1): | |
node.append((index*2-scale)*"*") if (index*2-scale) > 0 else None | |
for item in node: | |
print(item.center(scale)) |
This file contains 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
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8" /> | |
<meta name="viewport" content="width=device-width,initial-scale=1" /> | |
<title>Todo App</title> | |
<link rel="icon" type="image/png" href="favicon.png" /> |
This file contains 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
""" | |
selenium==4.6.0 | |
webdriver-manager==3.8.4 | |
packaging==21.3 | |
""" | |
import json | |
from selenium import webdriver | |
from selenium.webdriver.common.by import By |
This file contains 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
settings_module = __import__("settings.development", globals(), fromlist=[None], level=0) | |
for settings in dir(settings_module): | |
if not (settings.startswith('_') or settings.endswith('_')): | |
globals()[settings] = getattr(settings_module, settings) |