diff --git a/README.md b/README.md index 0035119..d3bd242 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,32 @@ # The `useclass.sty` Package: Load Classes as Packages ## Introduction -`useclass` is a package that enables the usage of classes as packages. It was originally designed for the `l3doc` class, which is employed for documenting LaTeX code with numerous useful features. However, employing the `l3doc` class as a package is not convenient when using the developing class as the style for the document. Therefore, this package provides a simple interface for utilizing classes as packages. +`useclass` is a package that enables the usage of classes as packages. +It was originally designed for the `l3doc` class, which is employed for documenting LaTeX code with numerous useful features. +However, employing the `l3doc` class as a package is not convenient when using the developing class as the style for the document. +Therefore, this package provides a simple interface for utilizing classes as packages. +The latest documentation is available [here](https://github.com/huangyxi/useclass/releases/latest/download/useclass.pdf). + + +## Installation + +The following methods are available for installing and updating the package. +Choose the method that best suits your needs. + +Since this package is derived from the `.dtx` file, the easiest way to install or update it is to place or replace the `useclass.sty` file in the same directory as your working document. +You can download `useclass.sty` from the [GitHub Release](https://github.com/huangyxi/useclass/releases/latest/download/useclass.sty). + +For a full installation of the package, you can use a TeX repository manager such as TeX Live. +This method will download the package from CTAN and install all required files to TeX Directory Structure (TDS). +For command-line users, the following commands can be used: + +```bash +tlmgr [--usermode] install useclass +tlmgr [--usermode] update useclass +``` + +If you're a developer interested in contributing to the project's development, or if you simply want to try the latest features before they are released, you can clone the repository from GitHub and use either `l3build` or `make` to install the package. + ## Usage Use `\useclass` to load a class with the same usage as `\usepackage`: diff --git a/useclass.dtx b/useclass.dtx index b41ca61..efab463 100644 --- a/useclass.dtx +++ b/useclass.dtx @@ -69,7 +69,8 @@ \useclass*[full]{l3doc} \usepackage{mdframed} -\providecommand{\pkgname}{\pkg{\jobname}} +\providecommand{\name}{\jobname} +\providecommand{\pkgname}{\pkg{\name}} \begin{document} \DocInput{\jobname.dtx} \PrintIndex @@ -113,6 +114,31 @@ % The package \pkgname{} was initially released on 2024-03-05, under the LaTeX Project Public License Version 1.3c^^A % \footnote{\url{https://www.latex-project.org/lppl/lppl-1-3c.txt}} % or later, and is maintained at \url{https://github.com/huangyxi/useclass}. +% The latest documentation can be found at +% \url{https://github.com/huangyxi/useclass/releases/latest/download/useclass.pdf}. +% +% +% \section{Installation} +% +% The following are the methods for installing and updating the package. +% You can choose the method that is most suitable for you. +% +% Since this package is tangled from the \file{.dtx} file, +% the easiest way to install or update the package is to place or replace the \file{\name.sty} file in the same directory as your working document. +% You can find \file{\name.sty} at GitHub Release^^A +% \footnote{\url{https://github.com/huangyxi/useclass/releases/latest/download/useclass.sty}}. +% +% For a full installation of the package, you can use the \TeX repository manager, such as \TeX{} Live. +% This method will download the package from CTAN, and install all required files to \TeX{} Directory Structure (TDS). +% For command-line users, you can use the following command: +% \begin{verbatim} +% tlmgr [--usermode] install useclass +% tlmgr [--usermode] update useclass +% \end{verbatim} +% +% If you're a developer interested in contributing to the project's development, +% or just want to try the latest features before they are released, +% you can clone the repository from GitHub, and use either |l3build| or |make| to install the package. % % \section{Usage} %