Saturday, June 01, 2024

Change font size on Gnu chash

To chnage the GNU Cash font size on windows I created the file %APPDATA%\GnuCash\gtk-3.0.css with the contents:

  #gnc-id-main-window {
    font-size: 16pt;
  }
  
Source: GnuCash help

Sunday, April 09, 2023

Copy lineage OS to phone to install from there

 I was having problems installing lineage OS using the sideload method, so I decided to use the copy and install method.

The steps where:

  1.  Set the phone in recovery mode with TRW
  2. Copy the lineageOs zip to tmp with the command  adb push "lineage-14.1-20170921-nightly-oneplus2-signed.zip" /tmp
  3. Copy the  google apps adb push "open_gapps-arm64-7.1-nano-20170922.zip" /tmp
  4. In  TRW 
    1. Select Install
    2. Navigate to /tmp and select the file lineage-14.1-20170921-nightly-oneplus2-signed.zip
    3. Select additional zip and select  open_gapps-arm64-7.1-nano-20170922.zip
    4. Press install
  5. Reboot

On reboot I got the phone stuck because no SIM was present, the wizard kept crashing, I needed to install a SIM to pass this point.

Then I got the message "Sign in with a google account that was previously synced on this device", I logged in with the original google account, to validate the phone had not been stolen, but after that I could select a new google account to use in the phone

 


Sunday, September 13, 2020

S3 Permissions to mail-in-a-box backup

 To backup mail-in-a-box to AWS S3 you need:

  1. Have a AWS account
  2. Create a S3 bucket to store the backups (you will need to note the region)
  3. Create a group, e.g. backup-email-group, with the single policy shown bellow
  4. Create a IAM user with programmatic access as a member of the backup-email-group. Note down the Access key and Secret Access Key
{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "VisualEditor0",
            "Effect": "Allow",
            "Action": "s3:ListBucket",
            "Resource": "arn:aws:s3:::my-bucket-name"
        },
        {
            "Sid": "VisualEditor1",
            "Effect": "Allow",
            "Action": [
                "s3:PutObject",
                "s3:GetObject",
                "s3:DeleteObject"
            ],
            "Resource": "arn:aws:s3:::my-bucket-name/*"
        }
    ]
}
This policy was posted in the mail-in-a-box forums.

Saturday, June 06, 2020

Update Lineage Os in a oneplus 2

The instructions posted here in the Lineage OS web site regarding the update of oneplus do not work for me, I can't get the command adb reboot sideload to work, it simply reboots my phone.
So these are the steps I took to update my phone to the latest version.
    1. Restart phone in recovery mode:
        power + volume down (will also take screenshot, just wait)
     or
        adb reboot recovery
    2. In TRW select Advanced > ADB sideload > slide to start sideloading
    3. Run command
    adb sideload .\lineage-17.1-20200601-nightly-oneplus2-signed.zip
wait...takes some time, you should see progress indicator
    4. In TRW select ADB sideload and run command
adb sideload .\open_gapps-arm64-10.0-nano-20200530.zip
    5.Reboot.. Wait a long time


Visual studio: start mutiple projects

There is a nice tool that allows you to define combination of multiple projects that should be started together when running things from Visual studio, the extension is called SwitchStartupProject and can be found here:

Tuesday, March 17, 2020

Visual studio: Class from XML or json

Visual studio has a nice hidden feature, that it is able to generate classes from XML and JSON data.
To be able to use you need:
  1. Create an empty class file (.cs file)
  2. Copy the JSON/XML to the clipboard
  3. Go to Visual Studio -> Edit -> Paste Special -> Paste as class
and you will be left with a nice class.

Sunday, December 08, 2019

Hack to include Gif in jAlbum

I'm currently using jAlbum version 13 (I highly recommend this software) and I came across the problem to include GIFs.
By default jAlbum was converting the GIF to JPG and using the generated file. To be able to include a GIF I do the following:
  1.  Create a gifs folder in the root of the output directory
  2. Copy the GIFs to this folder
  3. Open the project and drag an drop the GIFs to de desired location
    1. When asked, select to link the image
    2. Right-click the image and select "Include Original"
Now the GIF will be available as the ultimate link (after the slide page).

It seems that the newest version of jAlbum supports including GIFs as I expect it, but I have not tried it.

davidekholm wrote:
I've added support to use an original file as "closeup image" instead of a scaled/processed version to the upcoming jAlbum 13.10 now. This is perfect for making animated GIF images animate within slide pages. To try it out, ensure you're running jAlbum 13.9, then replace lib/jalbum-core.jar with this beta . You can also replace your texts/texts.properties file with the attached one.
Once done, right-clicking an image will reveal the new "Use original" option. Just click it and make the album again. Note, animated GIFs aren't supported by jAlbum's embedded web browser so you have to open the final album in an external web browser to see the animation.
References:
https://jalbum.net/forum/thread.jspa?threadID=52107 

Sunday, December 09, 2018

Add user to windows

WTF!? Why do I have to give option for password recovery when creating a local user account!!!

On windows 10, Going through the normal user dialogs is painful, Microsoft tries so hard to only allow you to add Microsoft accounts to your machine that is maddening.

If you just want to add a nice, simple local user account you will have to directly call the old add user application, to do you have to call it from the run command, so:
  1. Open the run command dialog: Windows key + R
  2. Open the user dialog, by running the command: control userpasswords2