Skip to main content
Create a package when custom commands are reused across multiple documents.

Minimal Package Skeleton

mypackage.sty
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{mypackage}[2026/02/16 Custom macros]

\RequirePackage{xcolor}
\newcommand{\todoitem}[1]{\textcolor{red}{TODO: #1}}
\newenvironment{note}{\begin{quote}\itshape}{\end{quote}}

\endinput

Use the Package

use-package.tex
\documentclass{article}
\usepackage{mypackage}

\begin{document}
\todoitem{Refine experiment section}
\begin{note}
Internal drafting note.
\end{note}
\end{document}