hisham hm

🔗 Remembering Windows 3.1 themes and user empowerment

This reminiscence started reading a tweet that said:

Unpopular opinion: dark modes are overhyped

Windows 3.1 allowed you to change all system colors to your liking. Linux been fully themeable since the 90s. OSX came along with a draconian “all blue aqua, and maybe a hint of gray”.

People accepted it because frankly it looked better than anything else at the time (a ton of Linux themes were bad OSX replicas). But it was a very “Ford Model T is available in any color as long as it’s black” thing.

The rise of OSX (remember, when it came along Apple had a single-digit slice of the computer market) meant that people eventually got used to the idea of a life with no desktop personalization. Nowadays most people don’t even change their wallpapers anymore.

In the old days of Windows 3.1, it was common to walk into an office and see each person’s desktop colors, fonts and wallpapers tuned to their personalities, just like their physical desk, with one’s family portrait or plants.

I just showed the above screenshots to my sister, and she sighed with a happy nostalgia:

— Remember changing colors on the computer?
— Oh yes! we would spend hours having fun on that!
— Everyone’s was different, right?
— Yes! I’d even change it according to my mood.

Looking back, I feel like this trend of less aesthetic configurability has diminished the sense of user ownership from the computer experience, part of the general trend of the death of “personal computing”.

I almost wrote that a phone UI allows for more self-expression today than a Win/Mac computer. But then I realized how much I struggled to get my Android UI the way I wanted, until I installed Nova Launcher that gave me Linux-levels of tweaking. The average user does not do this.

But at least they are more likely to change wallpaper in their phones than their computers. Nowadays you walk into an office and all computers look the same.

The same thing happened to the web, as we compare the diminishing tweakability of a MySpace page to the blue conformity a Facebook page, for example.

Conformity and death of self-expression are the norm, all under the guise of “consistency”.

User avatars forced into circles.

App icons in phones forced into the same shape.

Years ago, a friend joked that the inconsistency of the various Linux UI toolkits was how he felt the system’s “freedom”. We all laughed and wished for a more consistent UI, of course. But that discourse on consistency was quickly coopted to remove users’ agency.

What begins with aesthetics and the sense of self-expression, continues to a lack of ownership of the computing experience and ends in the passive acceptance of systems we don’t control.

Changes happen, but those are independent from the users’ wishes, and it’s a lottery whether the changes are for better or for worse.

Ever notice how version changes are called “updates” and not “upgrades” anymore?

In that regard, I think Dark Mode is a welcome addition as it allows a tiny bit of control and self-expression to the user, but it’s still kinda sad to see how far we regressed overall.

The hype around it, and how excited users get when they get such crumbles of configurability handed to them, just comes to show how users are unused to getting any degree of control back in their hands.

🔗 Writing release announcement emails

Mailing lists are not exactly fashionable nowadays, but some of them remain relevant for some communities. The Lua community is one such example. As of 2017, a lot of what goes on in the Lua module development world still resonates in lua-l. With over 2500 subscribers, it’s a good way to kickstart interest in your new project.

Mailing list users tend to be somewhat pedantic about etiquette guidelines for posting, especially for announcements and the like. So, I usually follow this little formula for writing release announcement emails, which has been effective for me:

  • Email subject - this is important; I use a format like “[ANN] MyProject x.y”
  • Summary - The first paragraph explains what is the project
  • Links and installation - Then a link to the project website, and a one-liner instruction of how to install it (that is, the incantation for the appropriate package manager — in the case of Lua, luarocks install myproject). More detailed instructions and documentation should be available from the project website.
  • Description - Finally, a more detailed description:
    • If the announcement is for a new version of an existing project that was previously announced on the list, I include a summarized changelog, essentially “What’s new in version x.y:”
    • If this is the first announcement of the project, then a longer description of how the project works. For Lua modules, for example, this may include a really short “hello-world”-type example for the library. This is information that should be in the README.md file for your repository, which in future announcements will be reachable via the link for the project website (often a Github repo URL) mentioned above.
  • License - Users should be able to figure out the license of your project easily, so especially in new projects mentioning can be a good idea — but watch out if you’re using a license that’s not the majority option in a given community. You may be unnecessarily flamed for your choice by people who don’t even want to use your project in the first place. If you’re not going with the “majority license” (and remember, license choice is your call as an author, not the community’s) it might be a better idea to avoid mailing list noise and mention the license only in the project website and sources. The goal is not to hide it (interested people should find it easily; do mention it in your project’s README.md and include a LICENSE file) but just to avoid licensing flamewars. Of course, using the majority license has major pros, so if it’s all the same to you go with it, but if you’d prefer another one, don’t let yourself be bullied by a community into picking one free software license over another. It’s your freedom too!
  • Be nice! - Finally, remember to sandwich all this technical info with greetings at the top, kudos to contributors, requests for help and feedback, etc. A mailing list is a social medium, after all. :)

An example of an upgrade announcement is here:

[ANN] LuaRocks 2.4.2

Hello, list!

I'm happy to announce LuaRocks 2.4.2. LuaRocks is the Lua package
manager. (For more information, please visit http://luarocks.org )

http://luarocks.org/releases/luarocks-2.4.2.tar.gz
http://luarocks.org/releases/luarocks-2.4.2-win32.zip

Those of you on Unix who are running LuaRocks as a rock (i.e. those
who previously installed using `make bootstrap`) can install it using:

   luarocks install luarocks

What's new since 2.4.1:

* Fixed conflict resolution on deploy/delete
* Improved dependency check messages
* Performance improvements when removing packages
* Support user-defined `platforms` array in config file
* Improvements in Lua interpreter version detection in Unix configure script
* Relaxed Lua version detection to improve support for alternative
implementations (e.g. Ravi)
* Plus assorted bugfixes and improvements

This release contains commits by Peter Melnichenko, Robert Karasek and myself.

As always, all kinds of feedback is greatly appreciated.

Thank you, enjoy!

-- Hisham

An example of a new project announcement is here:

[ANN] safer - Paranoid Lua programming

Hi,

Announcing yet another "strict-mode" style module: "safer".

* http://github.com/hishamhm/safer

Install with
   luarocks install safer

# Safer - Paranoid Lua programming

Taking defensive programming to the next level. Use this module
to avoid unexpected globals creeping up in your code, and stopping
sub-modules from fiddling with fields of tables as you pass them
around.

## API

#### `safer.globals([exception_globals], [exception_nils])`

No new globals after this point.

`exception_globals` is an optional set (keys are strings, values are
`true`) specifying names to be exceptionally accepted as new globals.
Use this in case you have to declare a legacy module that declares a
global, for example. A few legacy modules are already handled by
default.

`exception_nils` is an optional set (keys are strings, values are
`true`) specifying names
to be exceptionally accepted to be accessed as nonexisting globals.
Use this in case code does feature-testing based on checking the
presence of globals. A few common feature-test nils such as `jit` and
`unpack` are already handled by default.

#### `t = safer.table(t)`

Block creation of new fields in this table.

#### `t = safer.readonly(t)`

Make table read-only: block creation of new fields in this table
and setting new values to existing fields.

Note that both `safer.table` and `safer.readonly` are implemented
creating a proxy table, so:

* Equality tests will fail: `safer.readonly(t) ~= t`
* If anyone still has a reference to this table prior
  to creating the safer version, they can still mess
  with the unsafe table and affect the safe one.

About
-----

Licensed under the terms of the MIT License, the same as Lua.

During its genesis, this module was called "safe", but I renamed it
to "safer" to remind us that we are never fully safe. ;)

-- Hisham
http://hisham.hm/ - @hisham_hm

Hope this helps!

🔗 htop 2.0 released!

This week I finally released htop 2.0.0!

  • htop-2.0.0.tar.gz
  • MD5 06f76c7d644ce8ae611c9feb10439a30
  • SHA-256 d15ca2a0abd6d91d6d17fd685043929cfe7aa91199a9f4b3ebbb370a2c2424b5

What’s new in htop 2.0

Since version 2.0, htop is now cross-platform!
Check out the video and slides of my presentation at FOSDEM 2016
about how this came to be. This release includes code supporting Linux, FreeBSD, OpenBSD and Mac OS X.

There are also, of course, some new features:

  • If you’re using NCurses 6, htop will also support your mouse wheel for scrolling.
  • Moving meters and columns around in the setup screen is a lot more comfortable now.
  • You can now press “e” to see the set of environment variables for a process.
  • The “graph” mode for meters was revamped, inspired by James Hall’s vtop.

…And of course, lots of other tweaks and fixes!

Changelog

The changelog with the main new changes follows below. Special thanks
to everyone who contributed for this release, through bug reports, bug
fixes, new features and financial support for the platform abstraction
layer project!

  • Platform abstraction layer
  • Initial FreeBSD support
  • Initial Mac OS X support
    (thanks to David Hunt)
  • Swap meter for Mac OSX
    (thanks to Ștefan Rusu)
  • OpenBSD port
    (thanks to Michael McConville)
  • FreeBSD support improvements
    (thanks to Martin Misuth)
  • Support for NCurses 6 ABI, including mouse wheel support
  • Much improved mouse responsiveness
  • Process environment variables screen
    (thanks to Michael Klein)
  • Higher-resolution UTF-8 based Graph mode
    (Thanks to James Hall from vtop for the idea!)
  • Show program path settings
    (thanks to Tobias Geerinckx-Rice)
  • BUGFIX: Fix crash when scrolling an empty filtered list.
  • Use dynamic units for text display, and several fixes
    (thanks to Christian Hesse)
  • BUGFIX: fix error caused by overflow in usertime calculation.
    (thanks to Patrick Marlier)
  • Catch all memory allocation errors
    (thanks to Michael McConville for the push)
  • Several tweaks and bugfixes
    (See the Git log for details and contributors!)

🔗 How to make a pull request on GitHub - a quick tutorial

So you made changes to a project — a bugfix or maybe a new feature — and you want to send it for inclusion in the official (“upstream”) sources. Perhaps you sent an email or opened an issue in the bugtracker, and the project maintainers asked you to send a Pull Request (PR) on GitHub. But how to do this? Here’s a quick how-to guide!

Step 0 - Have a GitHub account

Before anything, you need to have a GitHub account! If you don’t have one already, go to github.com and sign up. Just follow the instructions, it’s easy and free.

Step 1 - “Fork the repository”

“Forking a repository” on GitHub means creating your own Git repository, which is a copy of the original.

Let’s visit a repository and fork it. Start by visiting https://github.com/hishamhm/pull-request-tutorial

In the upper-right there’s a button named “Fork”. It also shows a number: how many times this repository was forked by other people).

Press it, and it will create your own copy of the pull-request-tutorial repository, at https://github.com/YOUR_USERNAME/pull-request-tutorial (the real URL will, of course, contain your own username).

Step 2 - Download your fork and create a branch

Now, it’s time for you to make your changes in the source code (your bugfix or new feature). Start by downloading your repository to your computer. Go to the terminal, make sure git is installed in your computer and type:

git clone https://github.com/YOUR_USERNAME/pull-request-tutorial.git

This will download the files and create a directory called pull-request-tutorial that is linked to your fork (i.e. the copy of the repository under your control).

To avoid trouble later, let’s create a new “branch” in our repository so that the work on our bugfix or feature is stored separately. Pick a meaningful name that represents the changes you plan to make in your code. In our example, I’ll call it “fix-typo”:

git checkout -B fix-typo

Step 3 - Make your changes in your fork

Now enter the directory of your local fork, and edit it at will, implementing your bugfix or feature.

If you create a new file, remember to add it with git add:

git add new_file.txt

Commit your changes, adding a description of what was added. If you’re not used to Git, the simplest way is to commit all modified files and add a description message of your changes in a single command like this:

git commit -a -m "Fix typo in README file"

(But there are lots of ways to choose which files (and even parts of files) do commit and edit the commit message. Look for the Git documentation for details.)

Once your changes are committed, “push” the changes: send them to your GitHub repository using git push

git push

(The first time you push from a branch, Git will complain that your local branch in your computer is not connected to a branch in the GitHub server. Just do what the command tells you to do:

git push --set-upstream origin fix-typo

Next time you push again to this repository, just “git push” will do fine.)

Now, when you visit https://github.com/YOUR_USERNAME/pull-request-tutorial again, you should see your changes there.

Step 4 - Make the Pull Request

This is the simplest step! In your repository page, the next time you open the page after pushing to a new branch, there’s a big green button saying “Compare & pull request”. Press it!

This will open a page in which you’ll be able to further edit the description for your proposed changes. Write down a nice report explaining why these changes should be included in the official sources of your project, and then confirm.

The project authors will receive an email notification that you sent them a PR. Then it’s their turn to read it and comment. You will get notifications when they comment. If they suggest any changes to your bugfix or feature, go back to Step 3, edit it and push again: your Pull Request will be automatically updated. If they are happy with the changes and want to integrate your contributions to the project, the maintainers will click “Merge” and your code will become part of the original repository!

If you want to give it a try, feel free to use the repository I created for this tutorial: https://github.com/hishamhm/pull-request-tutorial

Fork it, edit it, commit and push your changes and send me a PR!

If you liked this tutorial, leave a star on its repo. :)

🔗 A story of violence and gender

[Even though the title foretells its content, I’ve been advised to add a trigger warning at the top of this post. It doesn’t hurt to be careful.]

It’s been a few days that I’ve been meaning to write this. I even discussed with a friend two days ago about when would be a good time. Emma Watson’s speech on gender equality yesterday (transcript and video) inspired me to go for it: “if not now, when?”.

I want to touch a delicate subject, which she brought up masterfully: how gender inequality works on men.

The story of any oppression is that of three roles: a mass of oppresed ones; a few who oppress them; and a mass who turns a blind eye, who are oppressors by proxy. This is the story of racism, of religious discrimination, and so on. Ms. Watson’s speech shines a light that the issue of gender equality is even more complex than that. Men are hurting women, and also hurting themselves in the process.

What made me want to write this was something that happened last week. I was with two friends, a guy and a girl, at a bar in a foreign country. (It was in Russia, but it could have been anywhere.) A disgusting scene happened. I didn’t see it firsthand, but the girl who was with us was looking straight at it, so I’ll reproduce her report:

At one point the guy who seemed to be the manager started to harass the waitress, just like that, in front of anyone. She froze. And so did I. She stood still in front of the counter while the man held her from behind rubbing his penis violently against her ass. I watched, petrified. I zoned out of my friends’ conversation. The pleasant look in the girl’s face was gone. After he let her go, I tried to approach her in another corner of the bar. The manager went to annoy two other women who were customers. One of them pulled her arm so he’d let her go. And they stayed in the bar! In the corner of the bar I asked the waitress [using Google Translator] if he was her boyfriend and if she was okay. She didn’t speak English, didn’t answer and just said “it’s okay, it’s okay.”

Of course it was not okay. My friend shared her concern with us. Dismayed as we were with it, our only reaction was to express our impotence with the situation. The reflex instinct of being part of “the mass who turns a blind eye”. We think ourselves better because we don’t do such things (and we probably are). Still, being “oppressors by proxy” is not a place we’re proud to be. Our sense of impotence, however, was very much real.

We said “What can we do?”. She said, “I don’t know, if he does it again I’ll make a scene in this place! A scandal!” Then I said “Women have that option.” I didn’t mean to sound rude, but that’s true. The way things work with men is that if we were to confront the (shirtless, tattooed, long-haired) guy, things would soon go violent. We told our friend: “What can we do? Get into a fist fight in a foreign country?” Her reaction was “Oh, men.”

This story highlights a less-discussed aspect in gender inequality. The prevailing rule of male violence serves not only to harm women, but also to stop other men from taking action. My male friend and I, we both knew we were under an unspoken law that if we were to do something, things would get violent.

(A flashback: The only time in my adult life that I got in a fist fight was years ago, also in Eastern Europe. I was walking down a street with a group of friends. Some guys across the street started yelling at the only woman in our group. She yelled back. They crossed the street and went for her. We stood in the way and it quickly got ugly. I think eventually someone shouted “police” and they ran away. One thing that strikes me from that story is that I’ve rarely retold it, and I’ve never seen any of my friends telling it. Men get ashamed of getting in a fight like that, even if it was for standing up for a woman. The other guys probably just made jokes about beating up some foreigners the next day.)

Back to last week’s story, we all felt the waitress really just meant “please don’t get into this”. Still, I wanted to think of something to do. If were we in our home country, we’d know how to report the manager in a safe way. We didn’t know if he owned the place, if anything we did would just get her fired, or worse. All these things crossed my mind.

We evidently didn’t want to stay in that place and give them any more money, so we spoke of leaving. We were waiting for a local friend, and I could just message him saying we had to leave. Then I told my friend “No, let’s wait for my friend and then we’ll explain him what happened and ask him to talk to her in Russian.” She replied, “Good idea.”

As soon as he arrived I told him the story, and that we wanted him to talk to the waitress about what happened before leaving. He seemed surprised; both with what happened and with our seriousness about it. We called her to our table. My Russian friend talked to her, and she told him that he was her boss, not a boyfriend, that he was “like that” but that it was “okay”. Before leaving the waitress went to my friend and repeated to her “it’s okay, it’s okay”, but her sad look said otherwise.

Even if she did think that enduring that guy was “just part of the job”, I hope that our concern reminded her that no, it’s not okay. And if she already felt it’s not okay (as I think she did), now she knows she’s not alone in thinking that, and that she’s not invisible. I’m very proud of my friend for reaching out for her, and shaking us up to do the same. The next day I had a long conversation about it in the airplane with my male friend who was there. These things matter.

We can’t fight gender inequality only by having women to stand up to men. Men have to stand up against inequality as well. And by “standing up” I don’t mean picking up fights. That is only reinforcing the gender stereotype. It’s a matter of redefining gender roles. I feel that society is slowly making progress (though clearly not at the same pace everywhere), but it’s a struggle into which both women and men need to take part. We men have to learn how.


Follow

🐘 MastodonRSS (English), RSS (português), RSS (todos / all)


Last 10 entries


Search


Admin