The End

Submitted by Calvin on Fri, 09/23/2022 - 23:18
Full Moon

The power went out at 11:35pm.

That was it.  That was the end.

 

That day seemed like any other day.  We worked our stupid jobs, stressed about our stupid things, watched our TVs.

 

PR to Env Workflow

Submitted by Calvin on Wed, 01/22/2020 - 17:53

More on git workflow! I love to think about this issue for some reason, so I’m always willing to discuss my thoughts about it with others, to understand their needs and refine my own processes/thinking.

Eventually I'll get comments or something running so the 0 people who read my blog can join me talking to myself. ;)

Enable/Disable Xdebug in Lando on the fly.

Submitted by Calvin on Wed, 12/18/2019 - 17:46
# Custom Lando commands
tooling:
   # xdebug: https://github.com/lando/lando/issues/1668#issuecomment-507191275
  xon:
    service: appserver
    description: Enable xdebug for apache.
    cmd: "docker-php-ext-enable xdebug && /etc/init.d/apache2 reload"
    user: root
  xoff:
    service: appserver
    description: Disable xdebug for apache.
    cmd: "rm /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini && /etc/init.d/apache2 reload"
    user: root

Wolf

Submitted by Calvin on Sun, 09/15/2019 - 12:39
Wolf

There were twin brothers who lived near a forest long ago. Sharing dreams of far off places and adventure. One day while chasing each other in the woods and play fighting with wooden swords, they discovered two wolf pups, weak and languishing at the base of a large oak. There seemed to be no pack around. The brothers determined the wolves would die if left alone and decided to care for them. They took the pups back home and nursed them to health.

Power ✊

Submitted by Calvin on Mon, 08/26/2019 - 16:25

Power is directly proportional to your ability to make decisions.

Ergo, power == the capacity to make decisions.

The more power you wield, the bigger the decisions you can make.
The bigger the decisions you’re capable of making, the more power you can wield.

Those two statements are equal.

You don’t get to make decisions for other people, if you haven’t convinced them that you’re capable of making good decisions, in their interest.

Drupal 8: views_query_alter - setLimit()

Submitted by Calvin on Fri, 04/19/2019 - 12:16

If you need change the limit of a views query dynamically it would seem obvious to use:

$query->setOffset($offset);
$query->setLimit($limit);

However, the pager overrides this.

To make this work use the following:

$view->setOffset($offset);
$view->getPager()->setItemsPerPage($limit);

Note these methods are on the $view object and not the $query object.