The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,676 other followers

Archive for the ‘Ruby’ Category

How not to structure your database-backed web applications: a study of performance bugs in the wild | the morning paper

Posted by jpluimers on 2018/09/25

This is about Ruby anti-patterns, which is a good step to start investigating the own anti-patterns you use in your own development environment:

[WayBack] How not to structure your database-backed web applications: a study of performance bugs in the wild | the morning paper

How not to structure your database-backed web applications: a study of performance bugs in the wild Yang et al., ICSE’18 This is a fascinating study of the problems people get into when using…

Via: [WayBack] How not to structure your database-backed web applications: a study of performance bugs in the wild… – Adrian Marius Popa – Google+

–jeroen

Posted in Design Patterns, Development, Ruby, Software Development | Leave a Comment »

I wish the Delphi language supported multi-line strings

Posted by jpluimers on 2018/06/21

Very often, I see people ask for how to embed multi-line strings in a Delphi source file.

The short answer is: you can’t.

The long answer is: you can’t and if you want you have to hack your way around.

The answer should be: just like any of these languages that do support multiline strings:

Many languages support this through a feature called HEREDOC.

Now in Delphi and other languages like Java are building ugly workarounds like for instance this one: [WayBackRAD Studio Tip: Using resource scripts to organize project dependencies. – Chapman World.

–jeroen

Posted in .NET, C#, Delphi, Development, JavaScript/ECMAScript, Python, Ruby, Scripting, Software Development | 17 Comments »

Let’s stop copying C / fuzzy notepad

Posted by jpluimers on 2017/12/07

Ah, C. The best lingua franca we have… because we have no other lingua francas. Linguae franca. Surgeons general? C is fairly old — 44 years, now! — and comes from a time when there were possibly more architectures than programming languages. It works well for what it is, and what it is is a relatively simple layer of indirection atop assembly. Alas, the popularity of C has led to a number of programming languages’ taking significant cues from its design, and parts of its design are… slightly questionable. I’ve gone through some common features that probably should’ve stayed in C and my justification for saying so. The features are listed in rough order from (I hope) least to most controversial. The idea is that C fans will give up when I call it “weakly typed” and not even get to the part where I rag on braces. Wait, crap, I gave it away.

Great re-read towards the end of the year: [WayBackLet’s stop copying C / fuzzy notepad

Via: [WayBack] Old and busted: emacs vs vi. New and hot: Language war, everybody against everybody else. – Kristian Köhntopp – Google+

–jeroen

Posted in .NET, APL, Awk, bash, BASIC, C, C#, C++, COBOL, CoffeeScript, CommandLine, D, Delphi, Development, F#, Fortran, Go (golang), Java, Java Platform, JavaScript/ECMAScript, Pascal, Perl, PHP, PowerShell, PowerShell, Python, Ruby, Scala, Scripting, Software Development, TypeScript, VB.NET, VBScript | 3 Comments »

Installing ruby gems on Windows

Posted by jpluimers on 2017/11/06

Steps:

  1. Install the Ruby Installer from rubyinstaller.org/downloads
  2. Add the directory where Ruby got installed to the user PATH (using "%windir%\System32\rundll32.exe" sysdm.cpl,EditEnvironmentVariables) in my case C:\Ruby23\bin as I installed Ruby 2.3.1
  3. Install the CA certificates:
    1. Download https://curl.haxx.se/ca/cacert.pem to the Ruby directory (C:\Ruby32)
      • Note this used to be at http://curl.haxx.se/ca/cacert.pem but serving that over http instead of https does not much sense when you want to secure your connections.
    2. Add the environment variable SSL_CERT_FILE with value C:\Ruby23\cacert.pem (again using "%windir%\System32\rundll32.exe" sysdm.cpl,EditEnvironmentVariables).

If you forget step 3, then you get errors like this:

C:\Users\jeroenp>gem install gist
ERROR:  Could not find a valid gem 'gist' (>= 0), here is why:
          Unable to download data from https://rubygems.org/ - SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (https://api.rubygems.org/specs.4.8.gz)

C:\Users\jeroenp>gem update --system
ERROR:  While executing gem ... (Gem::RemoteFetcher::FetchError)
    SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (https://api.rubygems.org/specs.4.8.gz)

–jeroen

References

Posted in Development, Ruby, Software Development | Leave a Comment »

“Network Graph of Programming Language Influence – White Background” Posters by ramiro | Redbubble

Posted by jpluimers on 2017/11/03

Via [WayBackGraph of programming languages influence poster – nice gift idea for programmers… – This is why I Code – Google+:

A network graph with more than a thousand programming languages connected by influence relations. Highly influential languages like Lisp, Smalltalk, C, Java, Pascal, C++, Haskel or Python are shown as larger circles as compared to languages with little influence on others like PHP or Argh!. / The influence relation data was retrieved from Freebase in 2013. This design available on posters and other products. An awesome gift for programmers who are into digital art. • Also buy this artwork on wall prints, apparel, kids clothes, and more.

[WayBack“Network Graph of Programming Language Influence – White Background” Posters by ramiro | Redbubble

I wonder how they drew the relations and why certain languages are in certain places.

–jeroen

Read the rest of this entry »

Posted in C, C++, COBOL, Development, Java, Java Platform, JavaScript/ECMAScript, Pascal, Perl, PHP, Python, Ruby, Scripting, Software Development, Turbo Prolog | Leave a Comment »

 
%d bloggers like this: