Skip to content

Instantly share code, notes, and snippets.

View eduard-sukharev's full-sized avatar

Eduard Sukharev eduard-sukharev

  • VK Play
  • Russia, Saint-Petersburg
View GitHub Profile
@thalamus
thalamus / ArchLinuxARM-M1
Last active March 11, 2024 16:55
How to boot Arch Linux ARM in QEMU (patched for M1)
/*
* This document is provided to the public domain under the
* terms of the Creative Commons CC0 public domain license
*/
How to boot Arch Linux ARM in QEMU (patched for M1)
Prerequisites:
QEMU - patched for M1 processors - patches: https://github.com/utmapp/qemu

Совет 1

Ставьте четкие цели. Создайте свою «стратегическую картонку» — список ключевых целей (как личных, так и рабочих) на текущий год. Это может быть закладка в ежедневнике, категория в Outlook, заметка в Evernote и т. п. Цели — это 3–5–7 важнейших достижений, которые вы по-настоящему хотите реализовать в ближайшие несколько месяцев.

Ставя цели, используйте конкретные, измеримые формулировки:

  • «Повысить личный доход на 20% к сентябрю»,
  • «Снизить вес на 4 кг в течение 2-го квартала» и т. п. Начинайте планирование дня со взгляда на свою «стратегическую картонку». Подумайте: «Какой шаг я могу сделать сегодня, чтобы достичь этих целей?»
@luk6xff
luk6xff / ARMonQEMUforDebianUbuntu.md
Last active April 23, 2024 17:11 — forked from bruce30262/ARMDebianUbuntu.md
Emulating ARM with QEMU on Debian/Ubuntu

You might want to read this to get an introduction to armel vs armhf.

If the below is too much, you can try Ubuntu-ARMv7-Qemu but note it contains non-free blobs.

Running ARM programs under linux (without starting QEMU VM!)

First, cross-compile user programs with GCC-ARM toolchain. Then install qemu-arm-static so that you can run ARM executables directly on linux

If there's no qemu-arm-static in the package list, install qemu-user-static instead

@eviltester
eviltester / gist:7beef92896fdd8b638656f996fac38c0
Last active September 28, 2023 15:12
Convert videos into subtitled sections using ffmpeg
# Create a new caption file
~~~~~~~~
ffmpeg -i captions.srt captions.ass
~~~~~~~~
# Add subtitles to main video without changing it
~~~~~~~~
ffmpeg -i video.mp4 -vf "subtitles=captions.ass:force_style='OutlineColour=&H80000000,BorderStyle=4,Outline=1,Shadow=0,MarginV=20'" subtitled-video.mp4
@denji
denji / README.md
Last active April 24, 2024 17:20 — forked from Cubixmeister/README.md
Simple Sentry docker-compose.yml
  1. Download docker-compose.yml to dir named sentry
  2. Change SENTRY_SECRET_KEY to random 32 char string
  3. Run docker-compose up -d
  4. Run docker-compose exec sentry sentry upgrade to setup database and create admin user
  5. (Optional) Run docker-compose exec sentry pip install sentry-slack if you want slack plugin, it can be done later
  6. Run docker-compose restart sentry
  7. Sentry is now running on public port 9000
@andriisoldatenko
andriisoldatenko / latency.txt
Last active February 18, 2018 07:16 — forked from jboner/latency.txt
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers
--------------------------
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD
@DeanCording
DeanCording / Template_ESP8266.ino
Last active April 29, 2023 03:23
ESP8266 Arduino project template with optional OTA firmware update
/**
* ESP8266 project template with optional:
* - WiFi config portal - auto or manual trigger
* - OTA update - Arduino or web server
* - Deep sleep
* - Process timeout watchdog
*
* Copyright (c) 2016 Dean Cording <dean@cording.id.au>
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
@alexbaumgertner
alexbaumgertner / js-courses.md
Last active November 24, 2021 05:24
JavaScript courses as on March 2016
@fsevestre
fsevestre / BooleanType.php
Last active December 26, 2018 16:15
Boolean form type for Symfony2 + tests (library: https://github.com/fsevestre/BooleanFormType)
<?php
namespace AppBundle\Form\Type;
use AppBundle\Form\DataTransformer\BooleanTypeToBooleanTransformer;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolver;
class BooleanType extends AbstractType
@chadrien
chadrien / README.md
Last active September 1, 2023 12:43
Debug PHP in Docker with PHPStorm and Xdebug

Debug your PHP in Docker with Intellij/PHPStorm and Xdebug

  1. For your local dev, create a Dockerfile that is based on your production image and simply install xdebug into it. Exemple:
FROM php:5

RUN yes | pecl install xdebug \
&amp;&amp; echo "zend_extension=$(find /usr/local/lib/php/extensions/ -name xdebug.so)" &gt; /usr/local/etc/php/conf.d/xdebug.ini \