Skip to content

Posts...

Page 19 of 49

Load FontAwesome Fonts with Webpack 2

January 23, 2017Category: Software
TL;DR: : Add the (s)css dependency to your main (s)css file and specify where to find the fonts too. Then use the proper loaders in your webpack.config.js file. The past few days I had trouble loading the font-awesome fonts with webpack. I tried quite a few solutions: Using the font-awesome-sass…

Copy File from Local Desktop to Remote Resktop Connection

January 19, 2017Category: IT
TL;DR: Drag-and-drop doesn't work. Copy&paste does! Before yesterday, my way of moving files between my local desktop and a remote one using MS Remote Desktop Connection involved a 3rd party service like Dropbox or email. Then, a kind soul took pity on me and showed me the proper way. In his words…

Multiline Regex in Visual Studio Code

January 6, 2017Category: IT
Setting up a multi-line regular expression in VS code is done by explicitly matching the CR/LF characters using \r?\n . For example, if I want to find all lines starting with a [ , including subsequent blank lines, I can do: HTH,

Scan Decorated Classes in Typescript

December 21, 2016Categories: Software, Tutorial
TL;DR: Make the decorator set a property in the class and look for it. While trying my hand at writing an ORM, I had a problem of initialising the database through a dummy instantiation of some models, without running an explicit command. In java, I can use code generation to provide a list of…

Make Electron Work with Sqlite3

December 16, 2016Categories: Software, Tutorial
The other day I tried to integrate knex with a SQLITE3 back-end. Unfortunately, the instant I've tried to instantiate knex , I've got a lot of errors . After getting rid of them, I found that I can't get sqlite3 to work at all, even though I've checked the installation and it was OK (got the…

Make Electron work with Knex.js

December 16, 2016Categories: Software, Tutorial
To make my life easier (and because I hate writing SQL statements), I thought of installing an ORM. After some search, I've decided to use knex . Unfortunately, the moment I integrated it into my app, webpack started generating errors like: ERROR in ./~/knex/lib/dialects/maria/index.js Module not…

Electron AppSend Menu Command to Angular App

December 9, 2016Categories: Software, Tutorial
TL;DR: In the main process use mainWindow.webContents.send('cmd') and in your Angular component ( renderer process) bind it to a method with ipcRenderer.on('cmd', this.open.bind(this)) (where open() is a method). I need to make my angular app work when a menu item is clicked (think: I…

List Columns in a ResultSet

December 8, 2016Categories: Software, Tutorial
In order to list all columns in a JDBC ResultSet (e.g. for debug purposes), you need to iterate through its metadata: Note: Column numbers start from 1, not 0 (hence the md.getColumnName(i + 1) above). I usually wrap this in a if(logger.isTraceEnabled()) so it doesn't get triggered all the…

Make Tomcat Log Stuff to Console (in Eclipse)

December 7, 2016Categories: Software, Tutorial
TL;DR: in your project's src/main/resources add the CONSOLE setting to the log4j.properties file. While trying to add features to a web application, I stumbled on an odd situation: my Eclipse Console would show only log messages for tomcat processes, none of my logs. I've tried to add a…

Skip the EPSO Online Test

December 5, 2016Categories: EPSO, Tutorial
TL;DR: : Replace the end of the application URL from e.g. 1947_en to 1947/apply_en . These days, EPSO is in the habit of launching calls with multiple fields with a twist: each field has its own application page. So, if you just want to browse the fields for more details (e.g. Talent Screener…
PreviousNext

All tags