[-] akash_rawal@lemmy.world 1 points 6 days ago

You have to practice switching between neovim and other editors.

You have forgotten how to use a normal editor. I am not making it up, it is a real phenomenon. Similar to when SmarterEveryDay learned to ride a backwards bicycle he forgot how to ride a normal bicycle and essentially had to re-learn it. You have to re-learn how to use a normal editor.

34
submitted 4 weeks ago* (last edited 4 weeks ago) by akash_rawal@lemmy.world to c/programming@programming.dev
111
submitted 1 month ago by akash_rawal@lemmy.world to c/linux@lemmy.ml

I took each rating for games on Wine Application Database, mapped them to numbers (Garbage -> 1, Bronze -> 2, Silver -> 3, Gold -> 4, Platinum -> 5) and plotted a monthly average.

101
20
[-] akash_rawal@lemmy.world 18 points 4 months ago

Replacing "Programmers:" with "Program:" is more accurate.

spoilerTower of Hanoi is actually easy to write program for. Executing it on the other hand...

[-] akash_rawal@lemmy.world 16 points 4 months ago

How I lost a Postgres database:

  1. Installed Postgres container without configuring a volume
  2. Made a mental note that I need to configure a volume
  3. After a few days of usage, restarted the container to configure the volume
  4. ...
  5. Acceptance
45
submitted 6 months ago by akash_rawal@lemmy.world to c/linux@lemmy.ml

I was exploring direct links between machines, and basically failed to break something.

I assigned IP address 192.168.0.1/24 to eth0 in two ways.

A. Adding 192.168.0.1/24 as usual

# ip addr add 192.168.0.1/24 dev eth0
# ping -c 1 192.168.0.2
PING 192.168.0.2 (192.168.0.2) 56(84) bytes of data.
64 bytes from 192.168.0.2: icmp_seq=1 ttl=64 time=0.051 ms

***
192.168.0.2 ping statistics
***
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 0.051/0.051/0.051/0.000 ms
#

B: Adding 192.168.0.1/32 and adding a /24 route

# ip addr add 192.168.0.1/32 dev eth0
# # 192.168.0.2 should not be reachable.
# ping -c 1 192.168.0.2
ping: connect: Network is unreachable
# # But after adding a route, it is.
# ip route add 192.168.0.0/24 dev eth0
# ping -c 1 192.168.0.2
PING 192.168.0.2 (192.168.0.2) 56(84) bytes of data.
64 bytes from 192.168.0.2: icmp_seq=1 ttl=64 time=0.053 ms

***
192.168.0.2 ping statistics
***
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 0.053/0.053/0.053/0.000 ms
#

Does this mean that adding an IP address with prefix is just a shorthand for adding the IP address with /32 prefix and adding a route afterwards? That is, does the prefix length has no meaning and the real work is done by the route entries?

Or is there any functional difference between the two methods?

Here is another case, these two nodes can reach each other via direct connection (no router in between) but don't share a subnet.

Node 1:

# ip addr add 192.168.0.1/24 dev eth0
# ip route add 192.168.1.0/24 dev eth0
# # Finish the config on Node B
# nc 192.168.1.1 8080 <<< "Message from 192.168.0.1"
Response from 192.168.1.1

Node 2:

# ip addr add 192.168.1.1/24 dev eth0
# ip route add 192.168.0.0/24 dev eth0
# # Finish the config on Node A
# nc -l 0.0.0.0 8080 <<< "Response from 192.168.1.1"
Message from 192.168.0.1
[-] akash_rawal@lemmy.world 19 points 7 months ago

I was confused for a moment, because intuitively a CPU fan would look in the same direction as it blows air, so it should look into the heatsink. The fan looking away from the heatsink seems weird to me.

Or the owner installed the fan in the wrong direction.

[-] akash_rawal@lemmy.world 40 points 8 months ago

I actually like this. This would allow reuse of all the infrastructure we have around XML. No more SQL injection and dealing with query parameters? Sign me up!

[-] akash_rawal@lemmy.world 20 points 9 months ago* (last edited 9 months ago)

You have rust.

You get a horse and arrive at the castle within seconds but the horse is too old and doesn't work with the castle.

You remove the horse, destructure the castle and rescue the princess within seconds, but now you have no horse.

While you're finding a compatible horse and thinking whether you should write your own horse, Bowser recaptures the princess and moves her to another castle.

85

I am building my personal private cloud. I am considering using second hand dell optiplexes as worker nodes, but they only have 1 NIC and I'd need a contraption like this for my redundant network.

Then this wish came to my mind. Theoretically, such a one box solution could be faster than gigabit too.

100

Let alone including yourself in the picture. I know how you look like.

Let alone including your loved ones in the picture.

Even when their disappointment of having to face away from the monument is clearly visible in the photo.

And then you make them do stuff like 'hold the sun in your hands' or whatever.

301
7
submitted 1 year ago* (last edited 1 year ago) by akash_rawal@lemmy.world to c/programminghorror@lemmy.world
56
submitted 1 year ago* (last edited 1 year ago) by akash_rawal@lemmy.world to c/programming_horror@programming.dev
[-] akash_rawal@lemmy.world 52 points 1 year ago* (last edited 1 year ago)

~~Remove the battery~~ Wait, you can't do that these days...

[-] akash_rawal@lemmy.world 19 points 1 year ago

Go: Why is your every second sentence a caution?

[-] akash_rawal@lemmy.world 25 points 1 year ago* (last edited 1 year ago)

Everything seems to be way faster on Linux than on windows for some reason.

On one occasion I tested a build that took ~10 min on windows, in a Linux VM installed on the same machine, it finished in ~1min.

I have searched around for an answer for quite some time now, I could not find any definitive reason. Some say that process creation is slower on windows, some say IO is inefficient. Still struggling to explain 10x increase in throughput.

Here is a funny instance: https://emacs.stackexchange.com/questions/17783/why-does-emacs-take-longer-to-start-on-windows-than-on-linux

12
[-] akash_rawal@lemmy.world 14 points 1 year ago* (last edited 1 year ago)

Not caring about privacy is one thing. There is also a network effect; that is caring about privacy leads to poorer contact with family, friends, and people they care about. Privacy has been correlated with disadvantage.

The sad thing about it is that none of it is natural, the big wigs have rigged it this way. Sometimes I feel like the only winning move is to choose your peers, and if you cannot choose your peers, you cannot win this game.

view more: next ›

akash_rawal

joined 1 year ago