If you’re into interesting projects, don’t miss out on wish-lists, created by pypeaday.
amazon wish lists replacement
GitHub stars posts
If you’re into interesting projects, don’t miss out on wish-lists, created by pypeaday.
amazon wish lists replacement
Sometimes you get a PR on a project, but cannot review it without wrecking your current working setup. This might be because it needs to be compiled, or a new set of requirements. Git worktrees is a great way to chekout the remote branch in a completely separate directory to avoid changing any files in your current project.
# pattern # git worktree add -b <branch-name> <PATH> <remote>/<branch-name> git worktree add -b fix-aws-service-cnsn /tmp/project origin/fix-aws-service-cnsn
This will create a new directory /tmp/project that you can review the branch fix-aws-service-cnsn from the remote origin. If you have setup different remotes locally you can check for the name of it with git remote -v
The work on pyscript by pyscript.
PyScript is an open source platform for Python in the browser. Try PyScript: https://pyscript.com Examples: https://tinyurl.com/pyscript-examples Community: https://discord.gg/HxvBtukrg2
GitPython is a python api for your git repos, it can be quite handy when you need to work with git from python.
I recently made myself a handy tool for making screenshots in python and it need to do a git commit and push from within the script. For this I reached for GitPython.
How I Quickly Capture Screenshots directly into My Blog
GitPython is a python library hosted on pypi that we will want to install into our virtual environments using...
...
nvim-notify by rcarriga is a game-changer in its space. Excited to see how it evolves.
A fancy, configurable, notification manager for NeoVim
I came across smart-sec-cam from scottbarnesg, and it’s packed with great features and ideas.
A privacy-focused, intelligent security camera system.
Python, click install
Edit the System Environment Variables
Environment Variables button
Add the following path to your users Path Variable
Sometimes you just want python to do something else when you hit an exception, maybe that’s fire a text, slack message, email, or system notification like I wanted.
I am working on a quick and dirty python script designed to take screenshots and land them on my website in a single hotkey. With it being designed to run with a hotkey, if it were to error I would not see it.
I could have gone down a logging route, but honestly this is meant to be quick, dirty, and work on my system for me. I just want to get it in my system notification.
Python exposes sys.excepthook for just this case. Here is what I ended up doing to fire a system notification as well as printing the message. Yaya a log would be mroe appropriate, but this is designed to just get done quick and do the job I want it to do.
I recently was unable to boot into my home Linux Desktop, it got stuck at diskcheck fsck. I found that I was able to get in to a tty through a hotkey.
https://twitter.com/_WaylonWalker/status/1512281106120384519
There’s probably more to it, but to me its a full screen terminal with zero gui, not even your gui fonts. It does log into your default shell so if you have a comfy command line setup it will be here for you even though it looks much different without fonts and full colorspace.
Normally you have 6 TTY’s running, the first is dedicated to your desktop manager, which is your login screen it might be something like gdm or lightdm.
...
pygame events are stored in a queue, by default the most suggested way shown in all tutorials “pumps” the queue, which removes all the messages.
You don’t necessarily need a full boilerplate to start looking at events, you just just need to pygame.init() and to capture any keystrokes you need a window to capture them on, so you will need a display running.
import pygame pygame.init() pygame.display.set_mode((854, 480))
Let’s use pygames normal event.get method to get events.
events = pygame.event.get()
printing the events reveal this
...
One of the most essential concepts of pygame to start making a game you will need to understand is loading images and blitting them to the screen.
blit stands for block image transfer, to me it feels a lot like layering up layers/images in photoshop or Gimp.
I started by making a spotlight in Gimp, by opening a 64x64 pixel image and painting the center with a very soft brush.
This is what it looks like
...
From the same Author that brought us command line essentials like fd and bat written in rust comes pastel an incredible command-line tool to generate, analyze, convert and manipulate colors.
You can install from one of the releases, follow the instructions for your system from the repo. I chose to go the nix route. I have enjoyed the simplicity of the nix package manager being cross platform and have very up to date packages in it.
...
Dunk is a beautiful git diff tool built on top of rich.
Browsing through twitter the other day I discovered it through this tweet by _darrenburns.
https://twitter.com/_darrenburns/status/1510350016623394817
Before I dive in deep, I do want to mention that Dunk is super new and beta at this point. I am making it my default pager, because I know what I am doing and can quickly shift back...
...