Coder Social home page Coder Social logo

cli's People

Contributors

chrisjensen avatar dependabot[bot] avatar f1yn avatar nickpedersen avatar pascalopitz avatar tmhash avatar tmns avatar tommaitland avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

cli's Issues

raisely start not working on Linux

Use CTRL + C to stop
(node:62580) UnhandledPromiseRejectionWarning: TypeError [ERR_FEATURE_UNAVAILABLE_ON_PLATFORM]: The feature watch recursively is unavailable on the current platform, which is being used to run Node.js
    at Proxy.watch (fs.js:1441:11)

SCSS file not found in Github Action

Hey team, I just setup a new repo following the quickstart guides and using 2 worflows to deploy a staging and production environment.

Unfortunately this is the error I am bumping up into

image

This may be similar to #24 ?

To clarify, there are currently no .scss files in the stylesheet folder. I just ran raisely update and thats whats there.

NOTE: I am also using github envirnoments to store the secrets for each of the deployments.

Oh our repo is public so you can see it here: https://github.com/bamboocreativenz/livingsober-raisely

Any help would be much appreciated.

Seperate out Campaigns from .raisely.json

I realised that the UUIDs of campaigns may be something I could commit in my repo. While everything else definetly shouldn't be.

The reasoning, it enables me to create multiple github repos targeting different sets of campaigns. AND makes it a lot easier to onboard different devs into differend projects/clients work.

If my repo is public than yes I am exposing the uuid to the internet, which is not ideal. But to be honest I think its ok a malicious third party would still not have the API key or the login credentials.

Alternatively It would be good to set this via a seperate .env so we can share this amongst the developers while expecting each of them to still login with their own account.

Improve invalid CSS/SCSS error handling

Right now, any invalid Sass in styles will dump something like this to stderr:

Saving {campaignName}/_core/global.scss(node:54061) UnhandledPromiseRejectionWarning: StatusCodeError: 400 - {"status":400,"time":"2020-04-18T01:17:30.510Z","errors":[{"code":"invalid syntax","status":400,"message":"Sass error: \"Invalid CSS after \"}\": expected 1 selector or at-rule, was \".profilelist. .pagi\"\"","detail":"One or more of the values you sent was not of the correct syntax. Please check the format of the values you are sending.","title":"Invalid Syntax"}]}
    at new StatusCodeError (/Users/flynn/.nvm/versions/node/v12.13.1/lib/node_modules/@raisely/cli/node_modules/request-promise-core/lib/errors.js:32:15)
    at Request.plumbing.callback (/Users/flynn/.nvm/versions/node/v12.13.1/lib/node_modules/@raisely/cli/node_modules/request-promise-core/lib/plumbing.js:104:33)
    at Request.RP$callback [as _callback] (/Users/flynn/.nvm/versions/node/v12.13.1/lib/node_modules/@raisely/cli/node_modules/request-promise-core/lib/plumbing.js:46:31)
    at Request.self.callback (/Users/flynn/.nvm/versions/node/v12.13.1/lib/node_modules/@raisely/cli/node_modules/request/request.js:185:22)
    at Request.emit (events.js:210:5)
    at Request.EventEmitter.emit (domain.js:475:20)
    at Request.<anonymous> (/Users/flynn/.nvm/versions/node/v12.13.1/lib/node_modules/@raisely/cli/node_modules/request/request.js:1154:10)
    at Request.emit (events.js:210:5)
    at Request.EventEmitter.emit (domain.js:475:20)
    at IncomingMessage.<anonymous> (/Users/flynn/.nvm/versions/node/v12.13.1/lib/node_modules/@raisely/cli/node_modules/request/request.js:1076:12)
(node:54061) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:54061) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
โ ‡ Saving {campaignName}/_core/global.scss(node:54061) UnhandledPromiseRejectionWarning: StatusCodeError: 400 - {"status":400,"time":"2020-04-18T01:17:55.817Z","errors":[{"code":"invalid syntax","status":400,"message":"Sass error: \"Invalid CSS after \"}\": expected 1 selector or at-rule, was \".profilelist. .pagi\"\"","detail":"One or more of the values you sent was not of the correct syntax. Please check the format of the values you are sending.","title":"Invalid Syntax"}]}
    at new StatusCodeError (/Users/flynn/.nvm/versions/node/v12.13.1/lib/node_modules/@raisely

This should be cleaned up to only show the Sass error for this specific function. Otherwise, all stderr traces should be hidden behind a debug or verbose flag.

Add current campaign message to warning

I am aware that custom components are deployed org wide, so this is less important for components.

However for deploying scss it would be good if the warning also told you which campaign you are overiting.

Obviously it matters less if you have disabled the ability for users to edit files through the ui, but as we are transitioning our client from ui edits to source controlled edits, thats not the case for us.

image

Add CI support

It'd be beneficial to add the ability to integrate the cli into a CI workflow to automate the deployment of styles and components without the need to pull down and authenticate via login.

  • Support authenticating using a campaign key as an environment variable
  • Support selecting campaign automatically based on key
  • Remove need for user intervention if key is passed (assume that we're in an automated environment)

Can't upload sibling style files

In the documentation it indicates that Raisely will consolidate the style files into one file in alphabetical order.

Organise your CSS
No-one likes a CSS file that's a 1000 lines long. Raisely lets you organise your CSS into folders. You can create new folders and files in your CLI-supported project. Raisely will automatically concatenate them when compiling them, in alphabetical order.

But it does not tell you how to setup the file system to leverage this feature:

image

In the above screen shot I was trying to use @import to see if that made a difference. It did not and the CLI said the components had deployed with no errors, but the @importwas not in the remote file. Which would likely indicate it was a silent failure.

UPDATE: Ok I then ran raisely local and confirmed that there were scss transpile errors. ie variables in some code snippet I was playing with had not been declared, so the transpilation failed. This would have been a lot better to have seen in the result of the raisely deploy action. However Even after fixing these the code changes are still not deploying.

The CLI is either buggy or the documentation needs to be updated.

Seperate Component and Componenent SCSS styles from Campaign Styles

Hey team, now that I understand the system a bit better, namely that components still often need .scss to go along with them as their styling API for components is not as replete as stylesheets. I'd like to make a suggestion for a relatively easy short term improvement.

Have a seperate set of .scss files specifically for components that are loaded into every campaign. ie its an organisation level base style file(s)

AND than make sure that campaign styling is loaded with a default higher specificity than these styles - so it overrides them.

Once you have done this than I would update the api so its much clearer that there are different packages you are deploying. Something like what lerna does. That way its very clear your updating different packages.

Out the box a new raisely account would have 1 components package and 1 campaign package.

Generally language wise I like:

  • packages
  • campaigns (a type of package)
  • components (a type of package)
  • custom-styles.scss for the file accessible through the ui.

Alternatively you could make components operate at a per campaign level instead.

Anyway, food for thought.

Error for "raisely deploy"

Hi there,

When I run the command raisely deploy I get the following error:
image

This seems to happen for me across all campaigns.
The folder structure is exactly how it is created from the CLI when running raisely init and I have not modified the stylesheets. I am also on windows and using raisely CLI version 1.6.4.

Any help would be much appreciated, thanks.

Unable to download stylesheets

I've tried several campaigns today and each time I raisely init and select a campaign it downloads the components fine, but the stylesheets folder is always empty.

Add filters/Documentation for Molecules and Atoms

Back in the day I found Brad Frosts Atomic Design guidelines super inspirational. Not sure if this is where you are deriving these naming convensions from.

In anycase, it would be great if these were more cleary identifiable through the dev documentation. Maybe jsut adding them as a tag? it would at least be helpful for me. I'd look at the source code, but it doesn't look like that has been open-sourced.

image

Implement tests

  • Test for filesystem consistency (compare path/posix with path/win32)
  • Test CRUD with campaign assets (use CI secrets/ENV based auth)
  • Run audits during CI

Occasional CLI crash due to path inconsistency

Hi there,

Since the latest fixes the CLI has been working on windows but would often crash. I've been hesitant to create this issue because I can't figure out the exact steps to reproduce consistently, and I can usually just restart the CLI. However, the error is always the same and it happens quite frequently.

Here is a screenshot
image

It seems to be another path mapping inconsistency.

'raisely local' redirects to the live site

Hi there,

I am trying to use the raisely local command so I can modify some code and test it locally before pushing it to our live site.
I have just noticed that whenever I run this command (or visit http://localhost:8015 directly) it will redirect to the domain where the live site is hosted, rather than staying on localhost.

This makes it harder to try and update code on the live site without affecting the users.
Please let me know if there is a workaround for this.

Cheers,
Jack

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.