Based on: https://gist.github.com/kevin-smets/8568070
This gist outlines the steps needed to setup zsh, ohmyzsh and the powerlevel10k theme, available for anyone to follow.
-
Setup required dependencies
# update packages sudo apt update
| #!/usr/bin/env python3 | |
| import psycopg2 | |
| import sys | |
| import configparser | |
| # Read odoo.conf | |
| config = configparser.ConfigParser() | |
| config.read('/etc/odoo/odoo.conf') | |
| # Get database connection details from config |
| # Convert Purchase Order to Vendor Bill | |
| # Works for single record or multiple records | |
| log(f"Processing {len(records)} records") | |
| for po in records: | |
| log(f"Processing PO: {po.name}, Model: {po._name}, State: {po.state}") | |
| <div style="margin: 0px; padding: 0px;"> | |
| <p style="box-sizing:border-box;margin: 0px; padding: 0px; font-size: 13px;"> | |
| Hallo <t t-out="object.partner_id.name or ''">Brandon Freeman</t>,<br><br> | |
| We zijn blij je te informeren dat je bestelling is verzonden. | |
| <t t-if="hasattr(object, 'carrier_tracking_ref') and object.carrier_tracking_ref"> | |
| Jouw trackingreferentie is | |
| <strong style="box-sizing:border-box;font-weight:bolder;"> | |
| <t t-if="object.carrier_tracking_url"> | |
| <t t-set="multiple_carrier_tracking" t-value="object.get_multiple_carrier_tracking()"></t> |
| import { getSupabaseBrowserClient } from "@midday/supabase/browser-client"; | |
| import { getUserDetails } from "@midday/supabase/queries"; | |
| import { upload } from "@midday/supabase/storage"; | |
| import { useState } from "react"; | |
| export function useUpload() { | |
| const supabase = getSupabaseBrowserClient(); | |
| const [isLoading, setLoading] = useState(false); | |
| const uploadFile = async ({ bucketName, file, path }) => { |
| import { SupabaseClient } from "@supabase/auth-helpers-nextjs"; | |
| type UploadParams = { | |
| file: File; | |
| path: string; | |
| }; | |
| export async function upload( | |
| client: SupabaseClient, | |
| { file, path }: UploadParams, |
| "use client"; | |
| import { useUpload } from "@/hooks/useUpload"; | |
| import { getSupabaseBrowserClient } from "@midday/supabase/browser-client"; | |
| import { useDropzone } from "react-dropzone"; | |
| export function Attachments({ id }) { | |
| const supabase = getSupabaseBrowserClient(); | |
| const [files, setFiles] = useState<Attachment[]>([]); | |
| const { isLoading, uploadFile } = useUpload(); |
| version: "3.3" | |
| services: | |
| odoo: | |
| image: registry.gitlab.com/codeagency-intern/odooimage | |
| networks: | |
| - gateway | |
| - odoo | |
| container_name: ${ENV}-odoo-app | |
| environment: |
Based on: https://gist.github.com/kevin-smets/8568070
This gist outlines the steps needed to setup zsh, ohmyzsh and the powerlevel10k theme, available for anyone to follow.
Setup required dependencies
# update packages
sudo apt update
| #!/bin/sh | |
| # Cleanup docker files: untagged containers and images. | |
| # | |
| # Use `docker-cleanup -n` for a dry run to see what would be deleted. | |
| untagged_containers() { | |
| # Print containers using untagged images: $1 is used with awk's print: 0=line, 1=column 1. | |
| # NOTE: "[0-9a-f]{12}" does not work with GNU Awk 3.1.7 (RHEL6). | |
| # Ref: https://github.com/blueyed/dotfiles/commit/a14f0b4b#commitcomment-6736470 | |
| docker ps -a | tail -n +2 | awk '$2 ~ "^[0-9a-f]+$" {print $'$1'}' |
| # Ask for the user password | |
| # Script only works if sudo caches the password for a few minutes | |
| sudo true | |
| # Install kernel extra's to enable docker aufs support | |
| # sudo apt-get -y install linux-image-extra-$(uname -r) | |
| # Add Docker PPA and install latest version | |
| # sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 36A1D7869245C8950F966E92D8576A8BA88D21E9 | |
| # sudo sh -c "echo deb https://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list" |