How to render a tree like an HTML table: in a HTML page

This fiddle says it all, but let's go briefly over it.

Whenever you are building a table out of a tree, use <table>, <tr>, <td> tags or their CSS equivalents table, table-row and table-cell and apply display:contents to the elements that you intreleave with the table to preserve your tree without destroying the table layout.

Easy-peasy, but it took me a while to figure it out.

Несколько историй про подпольных программистов

Продажник-программист

Попал я однажды в организацию, занимающуюся организацией оффлайновых конференций. Им нужен был человек для поддержки сайта. Разговаривал со мной мужчина в пиждаке и при галстуке, представившийся начальником отдела продаж. От общих тем быстро перешли к техническим. Заглянули в код. Свой ORM, самописный шаблонизатор, немного устаревшие приёмы, но в принципе всё стройно, логично и однообразно. Я спросил, что стало с предыдущим программистом, на что собеседник рассказал мне историю.

Лет десять назад моего собеседника наняли на должность продажника. Чуть ли не в первую неделю работы он сломал ногу и сидел дома три месяца. Работать по специальности он не мог, но директор, зная что у моего собеседника инженерное образование, попросил наполнить контентом их сайт-визитку.

image

За три месяца тот сумел не только наполнить сайт контентом, но и создать простенькую систему управления конференциями. С напоминалками, расписанием и отзывами. Выйдя на работу, он продолжал поддерживать систему, самостоятельно заполняя её информацией о новых конференциях. Время приходилось урывать от основной работы, поэтому вскоре пришлось прикрутить учётные записи, чтобы коллеги сами поддерживали базу данных в актуальном состоянии. А там, где есть учётные записи для коллег, можно добавить и учётные записи посетителей.

Со временем он заметил, что стал проводить меньше времени на телефоне, а больше — за выборкой данных и за оформлением почтовых рассылок. Продажи организации росли, его личные — росли чуть больше, чем в среднем по организации. Да и не удивительно, ведь новые приёмы он реализовывал сперва на "своих" конференциях.

I went googleless on my phone

I have an 8-core arm64 beast called Moto X Force, it's somewhat close to Nexus 5X, so there are some LineageOS builds around.

KBC Mobile app checks for Safetynet, prints out a warning but works. Kudos to the developers. Bancontact app stops working after checking Safetynet. Whatsapp app can be downloaded from the official website. Telegram is available on F-Droid, Skype can be side-loaded as well.

What else is missing?

Tags: 

How to make a copy of an Eclipse update site

I'll probably never do it again, but just in case:

$ECLIPSE_HOME/eclipse -nosplash -verbose \
  -application org.eclipse.equinox.p2.metadata.repository.mirrorApplication \
   -source http://download.eclipse.org/releases/mars/ \
    -destination ~/tmp/mars-mirror-meta

$ECLIPSE_HOME/eclipse -nosplash -verbose \
    -application org.eclipse.equinox.p2.artifact.repository.mirrorApplication \
       -source http://download.eclipse.org/releases/mars/ \
           -destination ~/tmp/mars-mirror-arte

My fight for the best title to your story

Someone just made me a remark about the style of titles I give to bug tracker tickets. They are apparently too long and actionable, which leaves no space for the text in the description.

I am angry. If there is one area I feel being an expert, this is titles. I've been running a community website for over 15 years and it's been 10 years since my only moderation activity there is fixing titles while other people moderate comments for hate speech and obscenities.

The website is serving 600,000 page views per month, half of what it did in its heyday 6 years ago. Facebook took over its market. Still, it is one of the few websites of its kinds that survived until now.

When I started moderating titles, users took it personally, so I had to back off manual post-moderation and built a dozen pre-moderation filters that forced people to write proper titles. I blocked long sequences of uppercase letters, obscenities, too short and too long titles, duplicate postings, greetings, improper use of punctuation, series of exclamation and question marks and god knows what. It worked, but it drove away some readers from the website.

A few years later, I relaxed the pre-moderation filters and reintroduced post-moderation. This time, I sent automatic notifications to users as titles of their posts changed. I kept receiving complaints, I so I developed a few tricks that would reduce the number of complaints. Instead of rewriting a title, I took user text that represented the essence of the post and put it as the title, keeping the original spelling and even case, so that the user clearly sees that the titles come from his own post.

A programmer's joke

A CS student shows his lab assignment to the professor. The code works and even produces the correct output, but the professor mutters that the code is not OK:

— You have to choose variable names wisely. Names like i, j, foo and bar make your code unreadable. By next time, please use long, mnemonic variable names.

A few weeks later, the same student completes a new assignment and brings it to the professor. This time, his code is full of long_mnemonic_variable_i, long_mnemonic_variable_j, long_mneminic_variable_foo and long_mnemonic_variable_bar.

SWIFT vs. the progress

Just for the record and because I've been asked about this a couple of times, already:

Technically,

  • SWIFT became redundant after Diffie-Hellman key exchange protocol was described in 1976.
  • Euroclear became redundant when blockchain technology came out in 2009.

Pages