Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 29 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ jobs:
if: runner.os == 'Linux'
run: |
echo "DISTRIBUTION=AppImage" >> "$GITHUB_ENV"
sudo apt-get install libxkbcommon-dev libxkbcommon-x11-0 fuse libxcb-cursor-dev libcups2-dev libcurl4-openssl-dev
sudo apt-get install libxkbcommon-dev libxkbcommon-x11-0 fuse libxcb-cursor-dev libcups2-dev libcurl4-openssl-dev rpm

- name: Configure
run: cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DAPP_DISTRIBUTION=${{ env.DISTRIBUTION }}
Expand Down Expand Up @@ -144,6 +144,10 @@ jobs:
if: runner.os == 'Linux'
run: cmake --build build --target appimage --parallel

- name: Build Linux DEB and RPM packages
if: runner.os == 'Linux'
run: cmake --build build --target deb rpm

- name: Upload Windows zip Package
uses: actions/upload-artifact@v6
if: runner.os == 'Windows'
Expand Down Expand Up @@ -172,6 +176,20 @@ jobs:
name: NotepadAI-Linux-AppImage-${{ steps.qt.outputs.suffix }}
path: ${{ github.workspace }}/build/NotepadAI*.AppImage

- name: Upload Linux DEB package
uses: actions/upload-artifact@v6
if: runner.os == 'Linux'
with:
name: NotepadAI-Linux-DEB-${{ steps.qt.outputs.suffix }}
path: ${{ github.workspace }}/build/NotepadAI*.deb

- name: Upload Linux RPM package
uses: actions/upload-artifact@v6
if: runner.os == 'Linux'
with:
name: NotepadAI-Linux-RPM-${{ steps.qt.outputs.suffix }}
path: ${{ github.workspace }}/build/NotepadAI*.rpm

release:
name: Publish GitHub Release
runs-on: ubuntu-latest
Expand Down Expand Up @@ -223,6 +241,16 @@ jobs:
"NotepadAI-${TAG}-${suffix}-x86_64.AppImage"
gh release upload "$TAG" "NotepadAI-${TAG}-${suffix}-x86_64.AppImage"

# Linux DEB
mv "NotepadAI-Linux-DEB-${suffix}"/NotepadAI*.deb \
"NotepadAI-${TAG}-${suffix}-amd64.deb"
gh release upload "$TAG" "NotepadAI-${TAG}-${suffix}-amd64.deb"

# Linux RPM
mv "NotepadAI-Linux-RPM-${suffix}"/NotepadAI*.rpm \
"NotepadAI-${TAG}-${suffix}-x86_64.rpm"
gh release upload "$TAG" "NotepadAI-${TAG}-${suffix}-x86_64.rpm"

# macOS dmg
mv "NotepadAI-macOS-${suffix}"/NotepadAI*.dmg \
"NotepadAI-${TAG}-${suffix}.dmg"
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -71,3 +71,4 @@ __cmake_systeminformation
.ninja_lock
.ninja_log
build.ninja
.claude/settings.local.json
86 changes: 77 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,24 +34,92 @@ You can define mini-apps — small HTML/JS tools that run in a native WebView in

## Installation

Grab a binary from the [Releases](https://github.com/nullmastermind/NotepadAI/releases) page.
Download from the [Releases](https://github.com/nullmastermind/NotepadAI/releases) page.

| Platform | Format |
|----------|--------|
| Windows | Installer (.exe) or portable zip |
| Linux | AppImage |
| macOS | Disk image (.dmg) |
### Windows

## Building from source
Download the installer (.exe) or the portable zip. The installer registers file associations and adds a Start Menu shortcut. The portable zip runs from any folder with no install step.

You need CMake 3.21+, Qt 6.5+, Ninja, and a C++20 compiler (MSVC, clang-cl, GCC, or Clang).
### macOS

Download the disk image (.dmg), open it, and drag NotepadAI to Applications.

### Linux

#### AppImage (all distributions)

AppImage runs on any x86_64 Linux distribution without installation.

Requirements: FUSE 2 (`libfuse2`). Ubuntu 22.04+ and Fedora 38+ include it. On Ubuntu 24.04:

```bash
sudo apt-get install libfuse2
```

Run:

```bash
chmod +x NotepadAI-*.AppImage
./NotepadAI-*.AppImage
```

To integrate with your desktop, move to `~/.local/bin/` and use a tool like `appimaged`.

#### DEB package (Ubuntu 24.04+ / Debian 12+)

```bash
sudo apt install ./NotepadAI-*-amd64.deb
```

Uninstall: `sudo apt remove notepadai`

#### RPM package (Fedora 38+ / openSUSE Tumbleweed)

Fedora:

```bash
sudo dnf install ./NotepadAI-*-x86_64.rpm
```

openSUSE:

```bash
sudo zypper install ./NotepadAI-*-x86_64.rpm
```

Uninstall: `sudo dnf remove notepadai` or `sudo zypper remove notepadai`

### Building from source

You need CMake 3.21+, Qt 6.5+, Ninja, and a C++20 compiler.

Ubuntu/Debian build deps:

```bash
sudo apt-get install cmake ninja-build \
qt6-base-dev qt6-base-private-dev libqt6core5compat6-dev \
libxkbcommon-dev libxcb-cursor-dev libcups2-dev libcurl4-openssl-dev
```

Fedora build deps:

```bash
sudo dnf install cmake ninja-build \
qt6-qtbase-devel qt6-qt5compat-devel \
libxkbcommon-devel libxcb-devel
```

Build:

```bash
git clone https://github.com/nullmastermind/NotepadAI.git
cd NotepadAI
cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel
sudo cmake --install build --prefix /usr/local
```

For platform-specific details and packaging on Windows, macOS, and Linux, see [doc/Building.md](doc/Building.md).
For packaging details see [doc/Building.md](doc/Building.md).

## Multi-instance and portable mode

Expand Down
51 changes: 51 additions & 0 deletions cmake/PackagingLinux.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -88,3 +88,54 @@ add_custom_target(appimage
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
DEPENDS appdir download_linuxdeploy
)

# ---------------------------------------------------------------------------
# CPack shared metadata
# ---------------------------------------------------------------------------
set(CPACK_PACKAGE_NAME "notepadai")
set(CPACK_PACKAGE_VERSION "${PROJECT_VERSION}")
set(CPACK_PACKAGE_CONTACT "NotepadAI Maintainers <maintainers@notepadai.app>")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "AI-powered text editor")
set(CPACK_PACKAGE_DESCRIPTION
"NotepadAI is an AI-powered cross-platform text editor built with Qt6.")
set(CPACK_PACKAGE_FILE_NAME "NotepadAI-${PROJECT_VERSION}-Linux-x86_64")

# ---------------------------------------------------------------------------
# CPack DEB configuration
# ---------------------------------------------------------------------------
set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "amd64")
set(CPACK_DEBIAN_PACKAGE_MAINTAINER "NotepadAI Maintainers <maintainers@notepadai.app>")
set(CPACK_DEBIAN_PACKAGE_HOMEPAGE "https://github.com/nullmastermind/NotepadAI")
set(CPACK_DEBIAN_PACKAGE_DEPENDS
"libqt6core6 (>= 6.5), libqt6gui6 (>= 6.5), libqt6widgets6 (>= 6.5), libqt6network6 (>= 6.5), libqt6printsupport6 (>= 6.5), libqt6concurrent6 (>= 6.5), libxkbcommon0, libxcb-cursor0")
set(CPACK_DEBIAN_PACKAGE_RECOMMENDS "libsecret-1-0")
set(CPACK_DEBIAN_PACKAGE_SECTION "editors")
set(CPACK_DEBIAN_PACKAGE_PRIORITY "optional")

# ---------------------------------------------------------------------------
# CPack RPM configuration
# ---------------------------------------------------------------------------
set(CPACK_RPM_PACKAGE_ARCHITECTURE "x86_64")
set(CPACK_RPM_PACKAGE_LICENSE "GPL-3.0-or-later")
set(CPACK_RPM_PACKAGE_VENDOR "NotepadAI")
set(CPACK_RPM_PACKAGE_URL "https://github.com/nullmastermind/NotepadAI")
set(CPACK_RPM_PACKAGE_DESCRIPTION
"NotepadAI is an AI-powered cross-platform text editor built with Qt6.")
set(CPACK_RPM_PACKAGE_REQUIRES "qt6-qtbase >= 6.5, libxkbcommon, libsecret")
set(CPACK_RPM_PACKAGE_GROUP "Applications/Editors")

include(CPack)

# Custom target: build .deb package
add_custom_target(deb
COMMAND ${CMAKE_CPACK_COMMAND} -G DEB
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Building DEB package"
)

# Custom target: build .rpm package
add_custom_target(rpm
COMMAND ${CMAKE_CPACK_COMMAND} -G RPM
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Building RPM package"
)
125 changes: 125 additions & 0 deletions deploy/linux/INSTALL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
# Installing NotepadAI on Linux

NotepadAI is available for Linux in three pre-built formats and can also be built from source.

## AppImage (Universal — all distributions)

AppImage runs on any x86_64 Linux distribution without installation.

**Requirements:** FUSE 2 (`libfuse2`) must be available. Ubuntu 22.04+ and Fedora 38+ include it. On Ubuntu 24.04 install it with:

```bash
sudo apt-get install libfuse2
```

**Steps:**

```bash
# Download the AppImage from the GitHub releases page
chmod +x NotepadAI-*.AppImage
./NotepadAI-*.AppImage
```

To integrate with your desktop launcher, move the file to `~/.local/bin/` and create a `.desktop` shortcut, or use a tool like `appimaged`.

---

## DEB package (Ubuntu 24.04+ / Debian 12+)

The .deb package installs NotepadAI as a native system package and integrates with `apt`.

**Supported distributions:**

- Ubuntu 24.04 (Noble) and later
- Debian 12 (Bookworm) and later

These distributions ship Qt 6.5+ in their official repositories, which is required by the package.
For older Ubuntu/Debian versions use the AppImage instead.

**Install:**

```bash
# Download NotepadAI-*-amd64.deb from the GitHub releases page
sudo apt install ./NotepadAI-*-amd64.deb
```

**Uninstall:**

```bash
sudo apt remove notepadai
```

---

## RPM package (Fedora 38+ / openSUSE Tumbleweed)

**Supported distributions:**

- Fedora 38 and later
- openSUSE Tumbleweed

**Install on Fedora:**

```bash
# Download NotepadAI-*-x86_64.rpm from the GitHub releases page
sudo dnf install ./NotepadAI-*-x86_64.rpm
```

**Install on openSUSE:**

```bash
sudo zypper install ./NotepadAI-*-x86_64.rpm
```

**Uninstall on Fedora:**

```bash
sudo dnf remove notepadai
```

**Uninstall on openSUSE:**

```bash
sudo zypper remove notepadai
```

---

## Build from source

**Build dependencies:**

- CMake 3.21 or later
- Ninja
- Qt 6.5 or later (qtbase, qtnetwork, qt5compat modules)
- A C++17-capable compiler (GCC 11+ or Clang 13+)
- `libxkbcommon-dev`, `libxcb-cursor-dev`

On Ubuntu/Debian:

```bash
sudo apt-get install cmake ninja-build \
qt6-base-dev qt6-base-private-dev libqt6core5compat6-dev \
libxkbcommon-dev libxcb-cursor-dev \
libcups2-dev libcurl4-openssl-dev
```

On Fedora:

```bash
sudo dnf install cmake ninja-build \
qt6-qtbase-devel qt6-qt5compat-devel \
libxkbcommon-devel libxcb-devel
```

**Build and install:**

```bash
git clone https://github.com/nullmastermind/NotepadAI.git
cd NotepadAI
cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel
sudo cmake --install build --prefix /usr/local
```

The binary will be at `/usr/local/bin/NotepadAI`.