Sometimes you need to encrypt a text string or a whole file because it is not recommended (or desirable) to use it as is. What to do if you see yourself in this situation? Make use of the openssl command. The openssl program is a command line tool for using the various cryptography functions of OpenSSL’s crypto library from the…
FreeBSD: how to enable clipboard on Vim
If you have asked yourself “how to enable clipboard on Vim?” or “is it possible to access the system clipboard on Vim?“, the answer is: yes. This is how you can do it. Note: in this example I’m using FreeBSD, but the principle is the same in other *nixes. First, you need to get sure that you installed Vim package…
How To Install and Configure PHP-FPM and Apache 2.4 on FreeBSD
Are you looking for instructions about how to install PHP-FPM on FreeBSD or how to configure Apache 2.4 and PHP-FPM? Keep on reading. This is how I did it on my FreeBSD laptop. NOTE: I’m assuming you are in a hurry and want to get to the point ASAP. While I’m using FreeBSD at the time of this writing, the…
Use of undefined constant SIGINT
Recently, while setting up a FreeBSD laptop, I was configuring Phpactor as Language Server for PHP. The idea was to have it working in Vim through the YouCompleteMe plugin. While trying to start the Phpactor server, I received the following error (among others): Use of undefined constant SIGINT – assumed ‘SIGINT’ (this will throw an Error in a future version…
Vdebug: Xdebug not showing full array contents
Have you ever tried to debug some PHP code in Vim just to find that Xdebug won’t show the full array contents? Fortunately the DBGP protocol allows you to set features for debugging, such as the max length of data that the debugger returns. You can set these features in the Vim dictionary g:vdebug_features, and they will be sent to…
Bash API Contract Testing
We have been doing some API development at work, and at one point we started evaluating tools for API contract testing. One of the explored approaches was drafting a bash script that glued some native Linux tools together in order to achieve the desired results. That’s how this tool came to be. It is a proof of concept (POC) used…
Bash: echo ignores here-documents
Well, not quite. I mean, if you are trying to use here-documents with the echo command in bash and it seems you are getting an empty line instead, the issue might be that echo is displaying only the first line, and it turns out to be an empty one. Consider the following example: $ echo < this is not >…
Xdebug: vim stopping on the first line of the script when using vdebug
If you are using vdebug and you are facing the situation where vim is stopping in the first line of any script you want to debug (or if you want it to actually stop), make sure to modify the following value in your .vimrc file: let g:vdebug_options.break_on_open = 0 As the official documentation states: This determines whether the debugger should…
vim-gutentags ignoring exclude parameters from ctags
This is another quick-and-dirty post added with the solely purpose of helping someone facing the same issue. If you happen to be using vim-gutentags with vim, and are facing difficulties making it excluding certain paths from your tags file using the gutentags_ctags_exclude option in your vimrc, make sure that you are using the same file path format (relative vs. absolute)…
Magazon WordPress Theme Error
Yo!, what’s up? I’ll post this here in order to (hopefully) save someone some time: If you happen to be using a WordPress theme called Magazon (even the latest versions), you probably found out that it’s broken. The issue gets worst as in latest version of WordPress it is not evident what the problem is because WordPress suppresses the error…