hjertnes.blog

Emacs, flycheck and eslint

14.04.2019 18:04

The first thing I did was to disable eshint and standard.

Then make sure you have a .eslintrc or .eslintrc.js file in your repo; one of them is sufficient.

The next step is to install eslint and all your plugins, configs etc globally (yarn global add or npm i -g). There are ways to get it to work with per project installs, but this is way easier.

Then make sure eslint works. just run eslint –print-config . until it prints the config. Then run M-x flycheck-validate-setup (double check this command) and make sure it work, and restart emacs. And that should be it.

Likes from my Instapaper

12.04.2019 23:22

A while since last time, I wanted to automate this process a little bit. Then I didn’t hear back from Instapaper about a API token and I went for a less ideal solution. It is a lot better though. Long story short, I wrote a node script that parses a exported csv files. I’ll probably get it up on Github soon, I just need to clean it up. And I’ll probably get back to doing this weekly now that it takes much closer to a few minutes, than 15.

Assange

11.04.2019 19:27

  • Julian Assange is a piece of shit.
  • He has not been convicted of anything except “failure to surrender to the court”
  • I have no opinion about what WikiLeaks do today, but I was and still am a big supported of what they did back in 2010
  • Extraditation is a legal concept I have a lot of problems with, and is just a giant mess.
  • Especially when a country you’re not a citizen of or wasn’t in when the ‘crime’ occoured.
  • I get that Ecuador had problems with his behaviour, but anyone would get crazy by basically being in house arrest for close to 7 years.

Some minor adjustments to how I use my Seed

07.04.2019 20:43

I started out using both of the pen loops in the Seed, but I have since stopped doing that. I still carry two pens. But I keep on in the pocket on the outside instead. The reasons is that if I use both of them I have to use the inner most pen. Most of the time that is what I want to do, but sometimes I am using some other pen and it is kind of clumsy to have to take the inner most pen out to be able to write in my notebook.

Micro arcitecture

07.04.2019 20:42

When I say micro arcitectures I mean everything from micro frontends, to services and packages. This means that instead of having a utilities package and a ui-compontents package you may have 10-100 of smalelr packages instead of one large.

Or that you build a smaller app that may contain maybe 20 smaller apps instead of one huge.

There are reasons for this. But it is not because it gives you better performance or because it is easier. It is not.

When you break things up, you do this because you want to update things idenpenent of each other.

If you can push out an update to the login page when it is ready, and then you move over to the registration page and so on.

And on the packages side, you do it to have more flexibility. Let’s say there is a bug in the button package in the latest version. But all the others works fine. If you had a monopackage structure you’d have to wait. But with a micro package system you could just update everything except that.

But there are some things you need to remember if you are looking at this. This is for situations where you are a lot of developers, where build times are limiting how often you can relase. Or that things are so big that it is a real pain to deal with.

I have gone back and forth on this a lot. If smaller companies should do it at all. And I think it depends.

I think everyone should get into and get setup to build smaller packages, and to make smaller components that can be shipped independent of each other sooner than later. And then unless you are really big I’d start thinking about spinning off everything that feels like it is really different from the rest as its own thing.

What I use Emacs for

05.04.2019 22:03

This is a short list of the stuff I use Emacs for.

  • General text editing and notetaking
  • All my blog posts are written in Markdown using Emacs
  • Notes are written as text files
  • Programming in JavaScript, React, C#, ClojureScript, Cucumber tests, Bash scripts, PowerShell scripts and probably a lot more.

Why I love the Golden Bear

31.03.2019 22:59

I just finished a pack of Blackwings, and I’m back with the Golden Bear. And I really love this pencil.

Having a soft pencil feels really good, but my personal favourite is something a little bit firmer close to a HB. And the GB is just that.

It is not expensive at all. You could get 15 blackwings or 144 Golden Bears.

The thing I love about it is that it is a really good pencil, similar quality to the Blackwings, but it is not as nice. The result is that it is a lot cheaper. That means that it is easy to just carry a lot of them without it feeling very expensive.

24 bottle

31.03.2019 22:57

I’ve had a problem with not drinking enough water for a while now. Probably over a year. The issue have been that the water gets how, and then I had the feeling that I just refilled it, and I dont’ do it and five hours later I have still just had two mouthfulls of water.

Then I started to research water bottles that keeps it cold. And after a lot of time I spend a ridicolus amount of money ordering a 24Bottle from Italy.

They are the kind of company I love, that want to make the one bottle you ever have to buy. There are two different models, one double walled that keeps your water cold for 24 hours and one single walled. I went for the first option. I also went for a 850ML bottle. It is big, like a bottle of wine. But I like it a lot. I can fill it when I get up in the morning, drink cold water until it is empty. Usually a while before lunch. Then refill it and it usually last me until I get home from work.

The build quality is solid, and I like it a lot.

If you are looking for a good bottle, with a lot of design options I’d take a look at them.

Star systems

30.03.2019 11:18

If you want to have some kind of rating, stars are probably the kind of thing you’d start with.

I’m going to do the examples with movies.

I think there are two good ways to do this. Either by using a three star system plus the option to order the items within the top rating. That means that 1 star = did not like it, 2 = fine, 3 = i liked it. And then you can decide if you liked Rockey 1 better than China Town. I didn’t by the way.

The second option is to go with five stars. I don;t think most people understand how this one works. Because I guess most people have a lot with three stars, and a lot with 1 and a lot with 5. This is how I think it should be used: 1=don’t watch this, 2 = didn’t like it, 3 = fine, 4 = great, 5 = one of the best movies ever.

Headphone setup

28.03.2019 20:02

I have two pairs of headphones. One of them have a cable and hare big, while the others are wireless plugs that are very compact.

When I go somewhere I usually end up bringing both. They are my Apple AirPds and my ATH-M50x.

The AirPods are great, for what they are. And they are the best bluetooth sound thing I have ever used, from a UX perspective. The batteries are becoming worse, but still pretty good within the constraints.

While the M50x is what I prefer to use, because it is really comfortable, shuts out everything, and sounds way better. I love this pair of headphones because how much you get for how little money. The retail is $130, but you can find them at $100 if you have some time.

The way I do it is that when I walk around the house, walk the dog or walk from or to the train station I use the AirPods because then I need to be aware what’s hapening around me.

But everywhere else I use the M50x. I don’t want a Bluetooth version of them, but what I miss is a Lightning version of their cable.