mirror of
https://github.com/ryan4yin/nixos-and-flakes-book.git
synced 2025-06-25 22:41:51 +02:00
feat: update sidebar
This commit is contained in:
parent
3b2aae967e
commit
655569d7c0
@ -186,7 +186,10 @@ function themeConfigEnglish() {
|
|||||||
{
|
{
|
||||||
text: "Dev Environments on NixOS",
|
text: "Dev Environments on NixOS",
|
||||||
items: [
|
items: [
|
||||||
{ text: "Introduction", link: "/development/intro.md" },
|
{
|
||||||
|
text: "nix develop & pkgs.mkShell",
|
||||||
|
link: "/development/intro.md",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
text: "Dev Environments",
|
text: "Dev Environments",
|
||||||
link: "/development/dev-environments.md",
|
link: "/development/dev-environments.md",
|
||||||
@ -351,7 +354,10 @@ function themeConfigChinese() {
|
|||||||
{
|
{
|
||||||
text: "在 NixOS 上进行开发工作",
|
text: "在 NixOS 上进行开发工作",
|
||||||
items: [
|
items: [
|
||||||
{ text: "简介", link: "/zh/development/intro.md" },
|
{
|
||||||
|
text: "nix develop 与 pkgs.mkShell",
|
||||||
|
link: "/zh/development/intro.md",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
text: "各语言的开发环境",
|
text: "各语言的开发环境",
|
||||||
link: "/zh/development/dev-environments.md",
|
link: "/zh/development/dev-environments.md",
|
||||||
|
@ -2,11 +2,11 @@
|
|||||||
|
|
||||||
To simplify NixOS-related commands, I utilize a Makefile, which proves to be very convenient.
|
To simplify NixOS-related commands, I utilize a Makefile, which proves to be very convenient.
|
||||||
|
|
||||||
Alternatively, you can also use similar tools like [just](https://github.com/casey/just) and [cargo-make](https://github.com/sagiegurari/cargo-make) for this purpose. Here, I will provide my approach as a reference.
|
Alternatively, you can also use similar tools like [just](https://github.com/casey/just) and [cargo-make](https://github.com/sagiegurari/cargo-make) for this purpose. Here, I will provide my approach as a reference.
|
||||||
|
|
||||||
Below is an example of how my Makefile looks:
|
Below is an example of how my Makefile looks:
|
||||||
|
|
||||||
>**NOTE**: The target names in the Makefile should not conflict with any file or directory names in the current directory. Otherwise, the targets will not execute.
|
> **NOTE**: The target names in the Makefile should not conflict with any file or directory names in the current directory. Otherwise, the targets will not execute.
|
||||||
|
|
||||||
```makefile
|
```makefile
|
||||||
############################################################################
|
############################################################################
|
||||||
@ -62,4 +62,4 @@ idols-debug: aqua-debug ruby-debug
|
|||||||
|
|
||||||
By Save the above Makefile to the root directory of your Nix flake. Then, I can use `make deploy` to deploy the configuration to my local machine, and `make idols` to deploy the configuration to all my remote servers.
|
By Save the above Makefile to the root directory of your Nix flake. Then, I can use `make deploy` to deploy the configuration to my local machine, and `make idols` to deploy the configuration to all my remote servers.
|
||||||
|
|
||||||
This approach simplifies the execution of NixOS commands by abstracting them behind target names in the Makefile, providing a more user-friendly and convenient experience.
|
This approach simplifies the execution of NixOS commands by abstracting them behind target names in the Makefile, providing a more user-friendly and convenient experience.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user