Tag programming
107 bookmarks have this tag.
107 bookmarks have this tag.
A self-hostable personal cloud inspired by serverless platforms and cgi-bin.
A deep dive into the text mode editors we had and how they compare to today's
Unexpectedly good.
Идемпотентность — звучит сложно, говорят о ней редко, но это касается всех приложений, использующих API в своей работе. Меня зовут Денис Исаев, и я руковожу одной из бэкенд групп в Яндекс Такси. Сегодня я поделюсь с читателями описанием проблем, которые могут возникнуть, если не учитывать идемпотентность распределенных систем в своем проекте.
Giving write access to your contributors might motivate them to do more. Super cool!
Computers are amazing. So why is software so terrible?
Applying The Blue Angel Criteria To Free Software
The 1OPS principle is the single principle that had the biggest impact in my entire coding career. I gave some hints about it in a previous post, but I was suggested that it might warrant a post on its own to go more in depth.
There is a single advice I would give to anyone writing software, and specially to great devs : Always optimize your code for your most junior developers. I agree that it is not a very popular advice, but it is the one that, in my experience, give the biggest bang for the buck.
Работаем.
Лучше пользоваться несколькими языками, чем только одним.
Стажёром я получал мало, джуном получаю нормально.
any variable named
SECONDS
will automatically increment every second. Bash is bonkers
TempleOS has images in comments btw.
TLDR: предлагаю рассмотреть хранение исходных кодов программ в некоем бинарном формате вместо голого текста.
Felix on Vala, Zig, C++, Fortran, Ada, Scheme and Common Lisp.
Is this site running Feather Wiki? Seems so.
This article is part of the series Understanding ActivityPub, which takes a look at the ActivityPub protocol through the lens of real-world examples. The protocol exchanges are taken from ActivityPub.Academy, a modified Mastodon instance that shows ActivityPub messages in real time (see the announcement post).
This article is part of the series Understanding ActivityPub, which takes a look at the ActivityPub protocol through the lens of real-world examples. The protocol exchanges are taken from ActivityPub.Academy, a modified Mastodon instance that shows ActivityPub messages in real time (see the announcement post).
In this blog, we go on an interactive journey to understand common queueing strategies for handling HTTP requests.
A bottom-up, animated guide to HTTP load balancing algorithms.
When project scope is perfectly decomposed and management rules are clear and strict, speed of delivery is the virtue, not the quality.
It is very important to conduct regular code reviews within every software team, but it is not so easy to do them right; here are a few typical pitfalls.
Гайд, как правильно писать сообщения для коммитов. О важности упоминания не просто того, что делает изменение, а зачем оно это делает. Очень мудро.
BSD, C, httpd, SQLite: an open software stack for web applications
How about we measure the amount of times programmers touch the lines. Instead of counting the number of lines we’ll count how many times they were actually modified—we can get this information from Git (or any other SCM). The more you touch that part of the aircraft—the more effort you spent on it, right?
I called it Hits-of-Code (HoC) and created a small tool to help us calculate this number in just one line.
What a nice idea! I installed this program and ran it on Betula and Mycorrhiza codebases. For Betula it's 26350 HoC, for Mycorrhiza it's 137208 HoC. Yeah, Betula is still comparatively young! Hey, what about Mycomarkup? 23443. Oh wow, just a little less than Betula. I expected a small number.
Terrain rendering algorithm in less than 20 lines of code - s-macke/VoxelSpace
via https://t.me/optorepost/55
Если кратко, то там вся карта хранится в виде двух текстур, а "воксели" рендерятся хитрым образом, просто проходя по этим текстурам в нужном порядке.
EditorConfig helps maintain consistent coding styles for multiple developers working on the same project across various editors and IDEs. The EditorConfig project consists of a file format for defining coding styles and a collection of text editor plugins that enable editors to read the file format and adhere to defined styles. EditorConfig files are easily readable and they work nicely with version control systems.
A source-control branching model, where developers collaborate on code in a single branch called ‘trunk’ *,
resist any pressure to create other long-lived development branches by employing documented techniques. They
therefore avoid merge hell, do not break the build, and live happily ever after.
In Go, a string is a (possibly empty) immutable sequence of bytes. The critical word here for our purposes is immutable. Because byte slices are mutable, converting between string and []byte generally requires an alloc and copy, which is expensive.
What if such conversions were cached? That would make comparing strings so much faster!: two integer comparisons (len and ptr). This article explains how this approach could be implemented.
A library implementing this:
It looks pretty small and simple. Despite having only 81 stars, it is used by 67.4k GitHub packages. Transitive dependencies. Found it at work accidentally. OpenSource woes.
Innovation tokens and whatnot.
By wrapping errors and building well-formatted error messages, we can keep better track of where errors are happening. I often just add the name of the function being called to my error messages, but we can make the message say whatever we want. For example, I’ll often include parameter information in the error so I know which inputs caused the error.
Task is a task runner / build tool that aims to be simpler and easier to use
version: '3'
tasks:
hello:
cmds:
- echo 'Hello World from Task!'
silent: true
A guide to domain-specific types that make sense.
Programmers are the builders of ontologies.
Apple released a language for configs. It's well-designed, take a look. Has Go bindings. I would've considered it if I needed a config language.
Гришаев решил корабль Тезея.
The biggest design mistake I made with Amfora, my first community open source project, was autogenerating config files. On startup, the application looks for a config file, and creates one if it doesn’t exist, full of all the application defaults. At the time, I thought this was great, as it documents all the existing options, and makes them very visible to the user in case they want to change them. In the end, this decision created a lot of headaches and is not something I’d ever do again.
makeworld is right! I had the same problem in Mycorrhiza but didn't suffer great consequences because the configuration design didn't change much.
Alex tells us that, for him, baking and cooking are easier than programming and soldering, because the errors there average out. As for me, this is completely inverse.
In programming, an error never fixes itself. You can observe it and fix it, you can write tests. You can run the program multiple times. It's you who fixes it, and you can understand how it's done. It's measurable!
Meanwhile, cooking is a nightmare. Burning something is routine for me. Is that too much or too little oil? For how long do I fry? What do I do with these spices? Do they really affect the taste? And to observe something, I can't rely on symbolic things like text. No, I have to look (is this color good? No idea!), smell (as if I know the difference) and taste (nothing more inaccurate).
I'm happy when something can be cooked with a timer. 15 min for buckwheat? I'm in. I'm more happy when the time is short. 4 min for this thin kind of spaghetti? Already boiling water!
I mean, even boiling water is not simple. My parents told me to wait until the correct bubbles appear. I'm waiting for the scary ones. Also, salt is supposed to make it boil faster. How much salt do I add?
And I didn't even talk about plants, which Alex also considers easy. They're not 😭
Беру любой JSON и вижу, как его можно упростить, убрав лишнюю вложенность. Вдвойне обидно, что на эту вложенность кто-то тратил время, а она не нужна!
Where ActivityPub developers coordinate their efforts to make the Fediverse a great space for cooperation
A forum for the fedidevs. What's funny is this notice it shows on my outdated Safari:
Unfortunately, your browser is unsupported. Please switch to a supported browser to view rich content, log in and reply.
This sentence contains to a funky website that recommends some browsers. Links2 is not there for some reason.
I should join the forum though, as I'm a proud fedidev now!
Replacing all magic numbers with variables/constants is not always good. Think.
If there is one principle that should be added to the UNIX philosophy, it is:
"Finish your project."
Let me list my finished projects.
Uh...
I can't even say Mycorrhiza is finished despite it being in maintenance mode!
Martin came up with the idea of using something like the roots from semitic languages for naming things. I thought of the same before I read this article, but it's good to have it written down by somebody.
All these retrogrades usually forget about Unicode updates! If your finished software does not support the newest writing system, then something is wrong. Well, I'm just saying. Actually, I like finished software! One day, I'll write one.
Gitpod is a cloud development environment for teams to efficiently and securely develop software. Improve your team's developer experience by coding in a CDE.
Mysh recommended me this.
Результат всего этого счастья нужен в режиме реального времени и крайне важен. Пропускать нельзя ни одного замера, потому что основную работу по анализу данных исследователи выполняют после окончания эксперимента. Поэтому всё это богатство данных, помимо показа на экране, придётся записывать на жёсткий диск. Все 1,3 гигабайта данных в секунду. И потом читать в Matlab'е, NeuroExplorer'е или другой программе. Система, которая сохраняла 99,99999% данных, не прошла контроль качества и была забракована, потому что теряла до 13 тысяч замеров каждую секунду.
В комментах пишут ещё:
я долго мечтал войти в медицину и больше 5 лет пытался работать с врачами. в итоге пришёл к печальному выводу, что это очень трудные во взаимодействии люди. не умеют мыслить структурно, стараются постоянно держать лицо, привыкли к строгой иерархии и за её пределами работать не обучены. так что непреодолимое и авторитарное требование виндовса тут неудивительно.
Статью написал Alex Hitech, что уже показатель качества. И комментарии у него заводные:
Мозг необязательно должен быть человеческим. Большинство исследований мозга выполняются на крысах и мышах, — их мозг очень похож на наш, а стоят они не в пример дешевле.
Data classes are containers for your data—not behavior
Somehow, longer functions are good.
Hi, I'm Redowan Delowar—a wandering sciolist with a flair for ones and zeros. I learn, write, and tweet about Python, Go, SQL, and the broader landscape of software in general.
Use a better algorithm.
Use a better data-structure.
Use a lower-level system.
Accept a less precise solution.
Pick the simplest solution.