Skip to content
Merged
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
39 changes: 36 additions & 3 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,41 @@ jobs:
- name: Run tests
run: go test ./test/... -v -count=1

build:
name: Build check
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
cache: true

- name: Build backend
run: go build ./...

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 24
cache: npm
cache-dependency-path: app/package-lock.json

- name: Install frontend dependencies
working-directory: app
run: npm ci

- name: Build frontend
working-directory: app
run: npm run build

deploy-backend:
name: Deploy backend
needs: test
needs: [test, build]
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest

Expand Down Expand Up @@ -89,7 +121,7 @@ jobs:

deploy-frontend:
name: Deploy frontend
needs: test
needs: [test, build]
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest

Expand Down Expand Up @@ -151,4 +183,5 @@ jobs:
echo "Reloading Nginx..."
sudo -n /usr/bin/systemctl reload nginx

echo "Frontend deployed successfully."
echo "Frontend deployed successfully."

16 changes: 8 additions & 8 deletions app/src/pages/profile/Profile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -200,14 +200,14 @@ export function Profile() {

function openProfileEdit() {
setProfileForm({
name: profile.name ?? '',
phone_number: profile.phone_number ?? '',
building: profile.building ?? '',
hostel: profile.hostel ?? '',
department: profile.department ?? '',
house_number: profile.house_number ?? '',
block: profile.block ?? '',
type: profile.type ?? '',
name: profile?.name ?? '',
phone_number: profile?.phone_number ?? '',
building: profile?.building ?? '',
hostel: profile?.hostel ?? '',
department: profile?.department ?? '',
house_number: profile?.house_number ?? '',
block: profile?.block ?? '',
type: profile?.type ?? '',
});
setProfileError(null);
setIsEditingProfile(true);
Expand Down
Loading