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
25 changes: 0 additions & 25 deletions .github/workflows/ant.yml

This file was deleted.

26 changes: 26 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Java CI

on:
push:
branches: ["main"]
pull_request:
branches: ["main"]

jobs:
build:
runs-on: ubuntu-latest

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

- name: Set up JDK 21
uses: actions/setup-java@v5
with:
java-version: "21"
distribution: "temurin"
cache: "maven"

- name: Build backend
working-directory: backend
run: ./mvnw clean test
1 change: 1 addition & 0 deletions backend/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,4 @@ build/

### Environment ###
.env
.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import java.time.Instant;
import java.util.List;
import java.util.UUID;

public record StudentProfileResponse(
UUID id,
String college,
Expand Down
1 change: 1 addition & 0 deletions backend/src/main/java/com/studentos/dto/UserMapper.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ private UserMapper() {

public static UserResponse toResponse(User user) {
StudentProfile profile = user.getStudentProfile();

StudentProfileResponse profileResponse = profile == null ? null : new StudentProfileResponse(
profile.getId(),
profile.getCollege(),
Expand Down
8 changes: 1 addition & 7 deletions backend/src/main/resources/application.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
spring:
application:
name: studentos-backend
datasource:
url: ${DATABASE_URL:jdbc:postgresql://localhost:5432/studentos}
Expand All @@ -20,12 +18,8 @@ spring:
host: ${REDIS_HOST:localhost}
port: ${REDIS_PORT:6379}

server:
port: 8080

app:
jwt:
secret: ${JWT_SECRET:change-me-to-a-long-random-secret-at-least-256-bits}
secret: ${JWT_SECRET:change-me-to-a-long-random-secret-at-least-256-bits}
access-expiration-ms: ${JWT_ACCESS_EXPIRATION_MS:900000}
refresh-expiration-ms: ${JWT_REFRESH_EXPIRATION_MS:604800000}
cors:
Expand Down
Loading