Skip to content

Instantly share code, notes, and snippets.

View calevans's full-sized avatar
💭
EVERYTHING IS AWESOME!

Cal Evans calevans

💭
EVERYTHING IS AWESOME!
View GitHub Profile
@calevans
calevans / .bash_macros.sh
Created May 26, 2021 15:52
Lando macros I use
# Lando aliases and functions
# Author: Cal Evans
# Copyright 2021 All Rigths Reserved
# License MIT
#
# db
#
# Show what Lando (docker ) DB services are running and what port they are
# running on
#
@calevans
calevans / ipUpdater.sh
Created January 28, 2022 21:47
Update a record in a DNS Zone hosted at Digital Ocean
#!/bin/bash
#################### CHANGE THE FOLLOWING VARIABLES ####################
TOKEN="" // Digital Ocean API Token
DOMAIN="" // Domain Name
RECORD_ID="" // DO Assigned each record in a Zone file an ID. To update a record you need that ID.
LOG_FILE="/var/log/ips.txt"
########################################################################
CURRENT_IPV4="$(dig +short myip.opendns.com @resolver1.opendns.com)"
<?php
use FluentCrm\App\Models\Campaign;
use FluentCrm\Framework\Database\Orm;
use FluentCrm\App\Models\Lists;
$email = Campaign::create(
[
'email_subject'=>'Test Subject ' . date('Y-m-d H:i:s'),
'email_body'=>'This is the body of the email.',
'type'=>'campaign',
<?php
use FluentCrm\App\Models\Campaign;
use FluentCrm\Framework\Database\Orm;
use FluentCrm\App\Models\Lists;
use FluentCrm\App\Services\CampaignProcessor;
$listName = 'scuba-news-list';
$listApi = FluentCrmApi('lists');
$list = $listApi->get()->where('slug',$listName)->first();