Says it's deployed to Neocities- but new files aren't there

Hi there! I’m having a really confusing error with trying to deploy my site to neocities. I followed the tutorial by scumsuck and I thought I was able to get it to work. But when I went to my neocities page no update had been made.

I know my site is committed to the git hub and when I go to actions it says the workflow for deploy to neocities was successful. I’m not sure where the issue is since I”m not getting an error code at all. I’m still fairly new to web building so please bear with me

https://github.com/gelalasey/magic-carnival

Here is my git page - please let me know if there’s anything else I give context on.

Your github repo is set to private so no one can see it.

:melting_face: oops… fixed. thank you!

youre missing a build step. youre using astro, you need to build the site to produce the actual html files before uploading it

so try

jobs:
  deploy:
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v1
      - name: build astro
        run: npm run build
      # When the dist_dir is ready, deploy it to neocities
      - name: Deploy to neocities
        uses: bcomnes/deploy-to-neocities@v1
        with:
          api_token: ${{ secrets.NEOCITIES_API_TOKEN }}
          cleanup: true
          dist_dir: dist

i hand typed it here in the comment box so i cant guarantee it works exactly, but thats the idea!

edit: you probably wanna change cleanup to true, otherwise it wont delete files you deleted

edit 2: looks like build output is dist. updated the yml there

Okay now when I tried to deploy I did get a proper error this time

Run npm run build

npm run build

shell: /usr/bin/bash -e {0}

> dimensional-dwarf@0.0.1 build

> astro build

sh: 1: astro: not found

Error: Process completed with exit code 127.

dimensional-dwarf was the original name of the git I had linked up for my original build when I first installed astro…I then manually went into the files and renamed the project to a new name… If I hazard a guess this might be part of the issue?

How can I make sure everything is grabbing from the correct files?

ugh okay I may have figured it out - I think when I renamed my file basically I messed up my NPM module - and based on this post I’m just going to restart with a new build to make sure everything is clean.

long story short - don’t mess with files when you don’t know what you’re doing :clown_face:

oh oh wait wait wait

i just forgot to install astro on githubs computer

add an install dependencies step before

- name: install deps
  run: npm i

so yeah basically youre running on github’s computers, which dont have astro installed

wait wait you need to use node.js too

uh i forked your repo, ill just paste some of my code over, see my pr!

1 Like

also i have no idea how npm i and npm ci differ… but my code was copied from githubs tutorial on ghpages deployment (which you can do too, make a ghpages mirror for the site!) so ig that means its good

Sorry I went ahead and build a new one thinking that would help. Still get the “sh: 1: astro: not found

Error: Process completed with exit code 127.”

COuld you either fork this code or explain what you did to it :smiley: ?? sorry for all the trouble but I really appreciate it

i submitted a pull request for the original repo (magic-carnival), merge it and it should work i hope! Pull requests · gelalasey/magic-carnival · GitHub

1 Like

You are amazing THANK YOU. you have no idea how much stress I caused myself with this

2 Likes