Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
750a961
Using QT6 and installing packages in CMakelists.txt. Configuring sett…
sc74 Mar 17, 2024
d40c4a1
slide activation
sc74 Mar 17, 2024
4258ab4
Add shellprocess-final.conf file in shellprocess folder to run update…
sc74 Mar 17, 2024
b1c3a76
Add folder src/.astroarch for the update.zsh script to be placed in /…
sc74 Mar 17, 2024
f9b28f4
adding path to netinstall-software.yaml file
sc74 Mar 17, 2024
5bbde81
Deletion of plasma file for locales
sc74 Mar 18, 2024
2648843
Revert "Deletion of plasma file for locales"
sc74 Mar 18, 2024
59fa1ac
Deletion of plasma file for locales
sc74 Mar 18, 2024
5116012
Calamares_AstroArch full version, install system for users. To be tes…
sc74 Mar 30, 2024
4f4b32a
Add gps-ublox and minor changes
sc74 Apr 14, 2024
12d583a
Add informations panel for users
sc74 Apr 28, 2024
8d193b3
Add power supplies panel
sc74 Apr 28, 2024
2b07037
add pictures branding
sc74 Jun 6, 2024
fa29752
update shellprocess-final
sc74 Sep 25, 2024
b7d56bc
reduction of files and configurations
sc74 Sep 26, 2024
ae139c4
reduction of files and configurations-2
sc74 Sep 26, 2024
a9f7b2d
update file for build make.sh
sc74 Sep 26, 2024
24bb1e7
update file netinstall_software.yaml
sc74 Sep 26, 2024
186bb5d
update file run-astroarch-onboarding.sh
sc74 Sep 27, 2024
d2bd1ff
update before installing package
sc74 Sep 27, 2024
8f1e410
Update for startup and remove files
sc74 Sep 27, 2024
61dc9d0
Set/Unset privileges and remove autostart file
sc74 Sep 27, 2024
b9d04db
Start sudo AstroArch-onboarding.desktop
sc74 Sep 27, 2024
3b9649d
Allow pkexec with no password for calamares
sc74 Sep 27, 2024
eb49cc6
update astroarch-onboarding.desktop
sc74 Sep 27, 2024
83491c6
update astroarch-onboarding.desktop
sc74 Sep 27, 2024
a4b1b89
update files run-astroarch-onboarding.sh shellprocess-final.conf
sc74 Sep 29, 2024
625c976
New fork with all changes following an update issue
sc74 Oct 4, 2024
b1cf7ee
Delete modules
sc74 Oct 4, 2024
0899084
update images
sc74 Oct 26, 2024
952c7b8
add url in readme.qml
sc74 Oct 27, 2024
b0cab50
update astroarch-onboarding
sc74 Mar 26, 2025
c43e7e3
update script
sc74 Mar 26, 2025
06f3add
update onboarding
sc74 Mar 27, 2025
999238c
update polkit
sc74 Mar 27, 2025
80a2896
update onboarding service
sc74 Mar 27, 2025
0561740
update netinstall
sc74 Mar 28, 2025
699020e
update script
sc74 Apr 3, 2025
441313c
Update conf files
sc74 Aug 26, 2025
157b46e
Update and cleanup
sc74 Aug 28, 2025
89b4059
Update for xrdp
sc74 Sep 1, 2025
d05921a
Some minor updates
sc74 Sep 4, 2025
a8a21e2
Minor updates
sc74 Sep 4, 2025
fb4a15b
Minor updates2
sc74 Sep 4, 2025
20fdfd3
Add BUILD.md file to explain AstroArch-onboarding (Calamares)
sc74 Sep 6, 2025
6704e7d
Update files first configuration image
Sep 14, 2025
312a146
Update files onboarding .desktop with time delay
Sep 19, 2025
bcc63de
Rename/delete folders and update files
Sep 21, 2025
b408062
Deleting files in autostart
Sep 23, 2025
6f86bf2
Update files .desktop
Sep 23, 2025
e2d3999
Merge branch 'devDucks:calamares' into calamares
sc74 Sep 24, 2025
6515235
astroarch_onboarding folder moved to /usr/share
Sep 25, 2025
f905962
Merge branch 'calamares' of https://github.com/sc74/astroarch-onboard…
Sep 25, 2025
904a55b
commit error
Sep 25, 2025
c51a31e
astroarch_onboarding folder moved to /usr/share
Sep 25, 2025
9639c56
Forgot to source zsh for update-astroarch
sc74 Oct 19, 2025
469099e
Update for Astroarch 2.0
Oct 20, 2025
d992578
Forgot a character in shellprocess command
Oct 20, 2025
d3170bc
Merge branch 'devDucks:calamares' into calamares
sc74 Oct 20, 2025
99dd205
Send DBUS_SESSION_BUS_ADDRESS to display notifications
sc74 Nov 5, 2025
793bf9c
Recovering Kstars/Indi configuration backups using the Astromonitor t…
sc74 Nov 11, 2025
ad9aad3
Increased timeout for updates and new optional packages
sc74 Nov 30, 2025
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
24 changes: 19 additions & 5 deletions make-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,20 @@ if [ $check_extracmakemodules -eq 0 ]; then
echo "extra-cmake-modules installed"
fi

check_base_devel=$(pacman -Q | grep -c base-devel)
if [ $check_base_devel -eq 0 ]; then
echo "base-devel not found... Installing"
sudo pacman -Sy base-devel --noconfirm
echo "base-devel installed"
fi

check_make=$(pacman -Q | grep -c make)
if [ $check_make -eq 0 ]; then
echo "make not found... Installing"
sudo pacman -Sy make --noconfirm
echo "make installed"
fi

# Build
mkdir -p build
cd build
Expand All @@ -41,8 +55,8 @@ cd ..
# Install files
sudo mkdir -p /usr/share/calamares/branding
sudo cp -R ./src/branding/astroarch /usr/share/calamares/branding/
sudo cp ./src/.astroarch/configs/49-nopasswd-calamares-vnc.rules /etc/polkit-1/rules.d/49-nopasswd-calamares-vnc.rules
sudo cp ./src/.astroarch/configs/49-nopasswd-calamares-xrdp.rules /etc/polkit-1/rules.d/49-nopasswd-calamares-xrdp.rules
sudo cp ./src/.astroarch/configs/com.github.calamares.calamares.policy /usr/share/polkit-1/actions/com.github.calamares.calamares.policy
cp ./src/.astroarch/configs/netinstall_software.yaml /home/astronaut/.astroarch/configs/netinstall_software.yaml
cp -r ./src/.astroarch/plugins/power_max_current /home/astronaut/.astroarch/plugins
sudo cp ./src/usr/share/astroarch_onboarding/configs/49-nopasswd-calamares-vnc.rules /etc/polkit-1/rules.d/49-nopasswd-calamares-vnc.rules
sudo cp ./src/usr/share/astroarch_onboarding/configs/49-nopasswd-calamares-xrdp.rules /etc/polkit-1/rules.d/49-nopasswd-calamares-xrdp.rules
sudo cp ./src/usr/share/astroarch_onboarding/configs/com.github.calamares.calamares.policy /usr/share/polkit-1/actions/com.github.calamares.calamares.policy
sudo cp -r ./src/usr/share/astroarch_onboarding /usr/share/

2 changes: 1 addition & 1 deletion removel_files_for_test.sh → remove_files_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
sudo rm /etc/polkit-1/rules.d/49-nopasswd-calamares-vnc.rules
sudo rm /etc/polkit-1/rules.d/49-nopasswd-calamares-xrdp.rules
sudo rm /usr/share/polkit-1/actions/com.github.calamares.calamares.policy
rm /home/astronaut/.astroarch/configs/netinstall_software.yaml
sudo rm /usr/share/astroarch_onboarding
rm -rf /home/astronaut/.astroarch/plugins/power_max_current
sudo rm -rf /usr/share/calamares
sudo rm /usr/lib/calamares/libcalamares.so
Expand Down
47 changes: 38 additions & 9 deletions src/modules/contextualprocess/contextualprocess.conf
Original file line number Diff line number Diff line change
Expand Up @@ -61,41 +61,70 @@ dontChroot: true
# "2020.2": "/bin/false february"
# "2019.4": "/bin/true april"
#"packagechooser_packagechooserq":


"packagechooser_kstars_indi":
"kstars_indi_stable":
- command: "-/bin/zsh -i -c use-astro-stable"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && use-astro-stable'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"
"kstars_indi_bleeding_edge":
- command: "-/bin/zsh -i -c use-astro-bleeding-edge"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && use-astro-bleeding-edge'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"

"packagechooser_astromonitorToken":
"*":
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && /usr/share/astroarch_onboarding/configs/astromonitor.sh'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"


"packagechooser_power":
"power_max_current":
- command: "-/bin/zsh -i -c power_max_current"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && power_max_current'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"
"power_standard":
timeout: 40

"packagechooser_gps":
"gps_on":
- command: "-/bin/zsh -i -c gps_on"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && gps_on'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"
"gps_off":
- command: "-/bin/zsh -i -c gps_off"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && gps_off'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"

"packagechooser_ftp":
"ftp_on":
- command: "-/bin/zsh -i -c ftp_on"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && ftp_on'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"
"ftp_off":
- command: "-/bin/zsh -i -c ftp_off"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && ftp_off'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"

"packagechooser_bluetooth":
"bluetooth_on":
- command: "-/bin/zsh -i -c bluetooth_on"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && bluetooth_on'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"
"bluetooth_off":
- command: "-/bin/zsh -i -c bluetooth_off"
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && bluetooth_off'"
timeout: 40
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"

49 changes: 49 additions & 0 deletions src/modules/packagechooser/Config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@
#include "utils/Logger.h"
#include "utils/Variant.h"

#include <QFile>
#include <QTextStream>

/** @brief This removes any values from @p groups that match @p source
*
* This is used to remove duplicates from the netinstallAdd structure
Expand Down Expand Up @@ -201,6 +204,7 @@ Config::updateGlobalStorage() const
}
if ( m_method == PackageChooserMethod::Legacy )
{

auto* gs = Calamares::JobQueue::instance()->globalStorage();
if ( m_packageChoice.has_value() )
{
Expand All @@ -210,6 +214,36 @@ Config::updateGlobalStorage() const
{
gs->remove( make_gs_key( m_defaultId ) );
}

const QString astromonitorKey = "packagechooser_astromonitorToken";

if ( m_astromonitorToken.has_value() )
{
gs->insert( astromonitorKey, m_astromonitorToken.value() );

const QString tokenValue = m_astromonitorToken.value();
const QString filePath = "/usr/share/astroarch_onboarding/configs/astromonitor_token.tmp"; // À AJUSTER

QFile file(filePath);
if (file.open(QIODevice::WriteOnly | QIODevice::Text))
{
QTextStream out(&file);
out << tokenValue;
file.close();
cDebug() << "Successfully saved astromonitor token to" << filePath;
}
else
{
cWarning() << "Could not open file for writing:" << filePath;
}


}
else
{
gs->remove( astromonitorKey );
}

}
else if ( m_method == PackageChooserMethod::Packages )
{
Expand All @@ -219,6 +253,21 @@ Config::updateGlobalStorage() const
{
cWarning() << "Unknown packagechooser method" << smash( m_method );
}

}

void
Config::setAstromonitorToken( const QString& astromonitorToken )
{
if ( astromonitorToken.isEmpty() )
{
m_astromonitorToken.reset();
}
else
{
m_astromonitorToken = astromonitorToken;
}
emit astromonitorTokenChanged( m_astromonitorToken.value_or( QString() ) );
}

void
Expand Down
10 changes: 10 additions & 0 deletions src/modules/packagechooser/Config.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ class Config : public Calamares::ModuleSystem::Config
Q_PROPERTY( QString packageChoice READ packageChoice WRITE setPackageChoice NOTIFY packageChoiceChanged )
Q_PROPERTY( QString prettyStatus READ prettyStatus NOTIFY prettyStatusChanged FINAL )

Q_PROPERTY( QString astromonitorToken READ astromonitorToken WRITE setAstromonitorToken NOTIFY astromonitorTokenChanged )

public:
Config( QObject* parent = nullptr );
~Config() override;
Expand Down Expand Up @@ -101,10 +103,15 @@ class Config : public Calamares::ModuleSystem::Config
QString prettyName() const;
QString prettyStatus() const;

QString astromonitorToken() const { return m_astromonitorToken.value_or( QString() ); }
void setAstromonitorToken( const QString& astromonitorToken );

signals:
void packageChoiceChanged( QString packageChoice );
void prettyStatusChanged();

void astromonitorTokenChanged( QString astromonitorToken );

private:
PackageListModel* m_model = nullptr;
QModelIndex m_defaultModelIndex;
Expand All @@ -121,6 +128,9 @@ class Config : public Calamares::ModuleSystem::Config
* Reading the property will return an empty QString.
*/
std::optional< QString > m_packageChoice;

std::optional< QString > m_astromonitorToken;

Calamares::Locale::TranslatedString* m_stepName; // As it appears in the sidebar
};

Expand Down
48 changes: 48 additions & 0 deletions src/modules/packagechooserq/ContextualProcessJob.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
/* === This file is part of Calamares - <https://calamares.io> ===
*
* SPDX-FileCopyrightText: 2017-2018 Adriaan de Groot <groot@kde.org>
* SPDX-License-Identifier: GPL-3.0-or-later
*
* Calamares is Free Software: see the License-Identifier above.
*
*/

#ifndef CONTEXTUALPROCESSJOB_H
#define CONTEXTUALPROCESSJOB_H

#include <QObject>
#include <QVariantMap>

#include "CppJob.h"
#include "DllMacro.h"

#include "utils/PluginFactory.h"

class ContextualProcessBinding;

class PLUGINDLLEXPORT ContextualProcessJob : public Calamares::CppJob
{
Q_OBJECT

public:
explicit ContextualProcessJob( QObject* parent = nullptr );
~ContextualProcessJob() override;

QString prettyName() const override;

Calamares::JobResult exec() override;

void setConfigurationMap( const QVariantMap& configurationMap ) override;

/// The number of bindings
int count();
/// The number of value-checks for the named binding (-1 if binding doesn't exist)
int count( const QString& variableName );

private:
QList< ContextualProcessBinding* > m_commands;
};

CALAMARES_PLUGIN_FACTORY_DECLARATION( ContextualProcessJobFactory )

#endif // CONTEXTUALPROCESSJOB_H
3 changes: 3 additions & 0 deletions src/modules/packagechooserq/PackageChooserQmlViewStep.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
#include "utils/System.h"
#include "utils/Variant.h"

#include "Job.h"
#include "ContextualProcessJob.h"

CALAMARES_PLUGIN_FACTORY_DEFINITION( PackageChooserQmlViewStepFactory, registerPlugin< PackageChooserQmlViewStep >(); )

PackageChooserQmlViewStep::PackageChooserQmlViewStep( QObject* parent )
Expand Down
33 changes: 33 additions & 0 deletions src/modules/packagechooserq/packagechooserq-qt6.qml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import QtQuick
import QtQuick.Controls
import QtQuick.Layouts


Item {
width: parent.width
height: parent.height
Expand Down Expand Up @@ -171,6 +172,38 @@ Item {
wrapMode: Text.WordWrap
}
}

Rectangle {
width: 700
height: 50
color: "#ffffff"
radius: 10
border.width: 0

Text {
x: 10
y: 15
text: qsTr("Recovering your backup with Astro monitor:")
font.pointSize: 10
}

TextField {
id: astromonitorInputField
x: 290
y: 10
width: 390
placeholderText: qsTr("Enter your astromonitor token here")
color: "black"
background: Rectangle {
color: "#f2f2f2"
}
placeholderTextColor: "darkgray"

onTextChanged: {
config.astromonitorToken = astromonitorInputField.text
}
}
}
}
}

Expand Down
6 changes: 3 additions & 3 deletions src/modules/packages/packages.conf
Original file line number Diff line number Diff line change
Expand Up @@ -202,9 +202,9 @@ pacman:
# "binutils", and then a second time for "wget". When installing large numbers
# of packages, this can lead to a considerable time savings.
#
#operations:
# - install:
# - vi
operations:
- install:
- base-devel
# - vi-${LOCALE}
# - wget
# - binutils
Expand Down
8 changes: 5 additions & 3 deletions src/modules/shellprocess/shellprocess-update.conf
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,10 @@ dontChroot: true
# ignored; the slowloris command has a different timeout from the
# other commands in the list):
script:
- command: "/bin/zsh -i -c update-astroarch"
timeout: 300
- command: "/bin/sed -i 's/%wheel ALL=(ALL:ALL) ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/g' /etc/sudoers"
- command: "-/bin/su astronaut -c 'source /home/astronaut/.zshrc && update-astroarch'"
- command: "/bin/sed -i '0,/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/s/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) ALL/' /etc/sudoers"
timeout: 7200

# You can change the description of the job (as it is displayed in the
# progress bar during installation) by defining an *i18n* key, which
Expand All @@ -91,4 +93,4 @@ script:
i18n:
name: "Update AstroArch"

timeout: 999
timeout: 9999
21 changes: 21 additions & 0 deletions src/usr/share/astroarch_onboarding/configs/astromonitor.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/bin/zsh

TOKEN_FILE="/usr/share/astroarch_onboarding/configs/astromonitor_token.tmp"
JETON=""

if [ -f "$TOKEN_FILE" ]; then
JETON=$(cat "$TOKEN_FILE")
fi

if [[ -n "$JETON" ]]; then

cd /home/astronaut
astromonitor --retrieve-backup ${JETON}
EXIT_CODE=$?

if [[ $EXIT_CODE -ne 0 ]]; then
notify-send --app-name 'AstroArch' --icon="/home/astronaut/.astroarch/assets/icons/novnc-icon.svg" -t 10000 'Astro Monitor' "❌ Astro Monitor was unable to import your Kstars backup"
else
notify-send --app-name 'AstroArch' --icon="/home/astronaut/.astroarch/assets/icons/novnc-icon.svg" -t 10000 'Astro Monitor' "✅ Astro Monitor has successfully imported your Kstars backup"
fi
fi
Loading