#development

1 messages · Page 143 of 1

hushed robin
#

exactly, I never asked for a solution I asked a question about the tos, so how does it make me stubborn for not implementing your suggestion?

sage bobcat
#

One message removed from a suspended account.

hushed robin
#

yes

wheat mesa
#

@earnest phoenix how should I name functions in C if there's no concept of methods on classes? Naming a method add seems kind of counterintuitive if there's a ton of different structures that all have a method named add

civic scroll
#

GATE JIETAI YEAAAAAAAA

radiant kraken
#

you can rewrite the resize function to utilize realloc

static void resize(Vector* v) {
  v->capacity *= 2;
  v->items = realloc(v->items, v->capacity);
}
#

@wheat mesa

radiant kraken
sharp geyser
#

That all looks so weird

radiant kraken
#

that would help when you're using an IDE Intellisense and type vector_

sharp geyser
#

👀

radiant kraken
#

i mean there's no concept of classes in C

sharp geyser
#

Ima do some more coding on my game

radiant kraken
#

everything must be a function

hushed robin
#

wait

#
const toProperCase = string => {
    const array = string.toLowerCase().replaceAll(' ', ',').replaceAll('_', ',').split(',');

    if (array.length === 1) {
        if (array[0].length >= 3) {
            return array[0].charAt(0).toUpperCase() + array[0].slice(1);
        } else {
            return array[0].toUpperCase();
        }
    } else {
        let newArray = [];

        for (const word of array) {
            if (word.length >= 3) {
                newArray.push(word.charAt(0).toUpperCase() + word.slice(1));
            } else {
                newArray.push(word.toUpperCase());
            }
        }

        return newArray.join(' ');
    }
}

module.exports = toProperCase;
#

rate my code

sharp geyser
#

const array = string.toLowerCase().replaceAll(' ', ',').replaceAll('_', ',').split(','); this looks weird

#

I mean if it works it works ig

neon leaf
#

const array = string.toLowerCase().split(/ |_/)

hushed robin
neon leaf
#

regex

hushed robin
#

i'm screaming

sharp geyser
#

regex to split based off whitespace

#

by the looks of it

neon leaf
#

yes

sharp geyser
radiant kraken
neon leaf
#

it splits either when a space is hit or when an underscore is hit

radiant kraken
neon leaf
#

the entire thing

hushed robin
#

cap

radiant kraken
#

try it and see

hushed robin
#

no way that will do all the code i just wrote

#

let me see

sharp geyser
#

that doesn't work null

hushed robin
#

if it does i will scream

sharp geyser
#

unless I am reading it wrong

#

which is highly likely

radiant kraken
#

that was the code i seen from volt

neon leaf
#

that doesnt work

sharp geyser
#

ye it does nothing

hushed robin
#

does not work

radiant kraken
#

oh wait

#

try changing it to /\b\w/g

#

it should work

hushed robin
#

does not work

sharp geyser
#

yep

#

You're smoking buddy

radiant kraken
#

bruh

sharp geyser
#

Works perfectly fine

hushed robin
#

not working for me

sharp geyser
#

skill issue

radiant kraken
#

that was the code volt used so

sharp geyser
#

if volt wrote it then it definitely works

hushed robin
neon leaf
#

this does too technically

string.split(/_| /).map((w) => w.length > 1 ? `${w[0].toUpperCase()}${w.slice(1)}` : w).join(' ')
sharp geyser
#

well you dingus thats now how it works

hushed robin
#

wym

sharp geyser
#

thats for proper case

#

so sentences like hello, world -> Hello, World

hushed robin
#

bruh

radiant kraken
#

^

hushed robin
#

then it doesn't do what i want it to

sharp geyser
radiant kraken
#

ok then code it yourself

hushed robin
#

i did already

#

lol

radiant kraken
#

good

sharp geyser
#

Why are you even seperating shit by _

rose warren
#

Ask chatgpt

radiant kraken
#

👍

hushed robin
sharp geyser
#

seems like you just wanted to overengineer and show off

hushed robin
#

thats what the api provides

#

_ or space

sharp geyser
#

if it provides both underscored and space seperated then use the space separated

sharp geyser
hushed robin
rose warren
sharp geyser
#

Well I have no love life and now have a restraining order so yes ||legal purposes this is a joke||

hushed robin
#

i can't chose which it gives

#

for some stuff it gives one

#

for some stuff it gives other

sharp geyser
#

is this not in separate fields?

neon leaf
hushed robin
#

what

hushed robin
#

i need it to work from caps

#

not small characters

rose warren
#

Battleless, have you heard about our lord and saviour ChatGPT?

hushed robin
neon leaf
#

so OKAY_HELLO to Okay Hello ?

hushed robin
#

people here got mad at me

radiant kraken
#

toLowerCase + replace /(_|\b)\w/g with x => x.toUpperCase @hushed robin

rose warren
#

I would recommend using chatgpt

hushed robin
rose warren
#

I use it all the time

sharp geyser
#

just use toLowerCase on the string first then

hushed robin
#

they always say my code is 100% chatgpt

sharp geyser
#

string.toLowerCase().split()

hushed robin
#

🙄

radiant kraken
#

i've never touched ChatGPT

#

and never will

sharp geyser
#

I don't trust chatgpt

#

now I use snapchat ai

hushed robin
#

why not

rose warren
#

People here complain about chatgpt the same way they start lang wars

radiant kraken
neon leaf
radiant kraken
hushed robin
neon leaf
#
string.split(/_| /).map((w) => w.length === 3 ? w.toUpperCase() : w.length > 1 ? `${w[0].toUpperCase()}${w.slice(1).toLowerCase()}` : w.length && w).filter(Boolean).join(' ') 
hushed robin
#

does with work with space and underscore

neon leaf
#

yes

#

try it

hushed robin
#

lemme see

sharp geyser
#

👀

hushed robin
#

ok

#

so it kinda works

#

but

#

is should be fully capped

neon leaf
#

didnt you say only words with 3 chars?

#

or do you mean more than?

#

ah nvm

#

hold on

hushed robin
#

i think the fix is easy

#

just changing signs

neon leaf
hushed robin
#

yup

#

wow w

neon leaf
#
string.split(/_| /).map((w) => w.length < 3 ? w.toUpperCase() : w.length > 1 ? `${w[0].toUpperCase()}${w.slice(1).toLowerCase()}` : w.length && w).filter(Boolean).join(' ') 
hushed robin
#

you did my whole code in one line

#

lmao

sharp geyser
#

those chained ternary operators tho

hushed robin
#

what does the .filter(Boolean) do

neon leaf
#

it should even be more performant since it only loops over the string / array 4 times instead of 5

neon leaf
#

so empty string

#

false

#

undefined

hushed robin
#

oh ok

neon leaf
#

null

sharp geyser
#

I thought an empty string is a truthy value in js

radiant kraken
#

it isnt

neon leaf
sharp geyser
hushed robin
sharp geyser
#

ah an empty array is the one that's truthy

#

got it mixed up

#

always do that

radiant kraken
#

imagine

sharp geyser
#

shut up null

radiant kraken
#

in python its falsy

hushed robin
neon leaf
sharp geyser
hushed robin
#

my bot works so good now

sharp geyser
#

I got it mixed up with an empty array

radiant kraken
#

python doesnt

sharp geyser
#

python is also a language for babies so

#

Also love how unity support is lackluster

radiant kraken
#

python is mid

sharp geyser
#

I've asked a question in their support channel and all they said was "it should work" and moved on

silk prairie
#

scratch is best

hushed robin
#

i think there was manga books in 2018

#

why is it saying theres no result

#

dumb anilist api

sharp geyser
#

or your code is broken

hushed robin
#

true

#

lets check

neon leaf
#

how healthy is this amount of useeffects

sharp geyser
#

looks normal to me

neon leaf
#

are you sure

sharp geyser
#

Why not?

neon leaf
#

I dont know

radiant kraken
#

what does useref in react do

neon leaf
#

just initiates a ref to a component

radiant kraken
#

?

#

i dont understand

neon leaf
#

in components you just do ref={captcha}

#

and then you can access the component using captcha.current anywhere

hushed robin
#

how come they can use year but i can;t

#

i hate this api

radiant kraken
#

what is .current

neon leaf
#

the current component

#

the ref is assigned to

radiant kraken
#

as in an Element object?

hushed robin
#

oh wait

#

i see

sharp geyser
#

Im going to fucking blow my head off with this Unity shit

neon leaf
#

not really

#

components can customize what refs see

#

for captcha it adds functions to it like resetCaptcha()

radiant kraken
#

ill never understand react

neon leaf
#

me neither

sharp geyser
#

i'll never understand unity

radiant kraken
#

all i know is just useeffect and usestate

neon leaf
#

uhh, so question related to my oauth flow

#

do I request a captcha when logging in with lets say github?

#

or is it enough that I get a token and know its them

radiant kraken
#

nope

neon leaf
#

to what did you say nope

hushed robin
sharp geyser
#

shut up battleless

radiant kraken
#

first

radiant kraken
neon leaf
#

alr, well it makes sense that way

radiant kraken
#

stop telling people to shut up

sharp geyser
#

or what

hushed robin
#

why isn't this query working?

#

specifically only with type and startDate

#

I'm sending a variables type as MANGA and startdate as 2018 but for some reason it's returning empty
(and if I do it from the editor it returns data)

civic scroll
#

what error

hushed robin
radiant kraken
#

@neon leaf after an hour of reading react docs, i finally understand what useref does poggythumbsup

#

thanks

hushed robin
#

code not returning data

#

editor is returning data

civic scroll
#

i'm asking for runtime error

#

like did the function you used for the gql query emitted any kind of error

#

the "code not returning data" is so generic that even you can be put as its alias

hushed robin
#

there is no error

#

the query is not returning data

#

when it should

civic scroll
#

sounds like "you are not entering the right query, when you should"

#

without error i can't help
cc @lyric mountain to look at this

hushed robin
#

cuh it works in editor

#

and returns data

civic scroll
#

also

hushed robin
#

but in my code no work

civic scroll
#

your code has issue then

hushed robin
#

no

civic scroll
#

cuh

hushed robin
#

it’s the same

#

as editor

civic scroll
#

if it's the same, then it should work

hushed robin
#

yes it should

#

but it ain’t pal

#

🗿

#

that is why im here asking skilled graphql users for help

proven lantern
pale vessel
#

read

#

:/

hushed robin
#

and that’s not what I mean

#

☹️

pale vessel
#

look at how you did it and how I did it

#

there's no YEAR for MANGA

#

why not use start year?

hushed robin
#

I did startDate

pale vessel
#

you did year

hushed robin
#

no

pale vessel
#

you can also do 20180000 for startDate to filter only 2018 manga

hushed robin
#

bro

#

I did 2018 and it did not work

pale vessel
#

it's prob some other filter

hushed robin
#

no

#

that’s the only filter

pale vessel
#

works for me, so you did something wrong

hushed robin
#

yes I’m

#

ik

#

it works there

#

I said that above

#

but it doesn’t in my code

pale vessel
#

there's no seasonYear for manga man

#

season too

hushed robin
#

those don’t matter

pale vessel
#

they do, see here

#

you fixed a similar issue by removing unrelated filter

hushed robin
#

that is different

#

If you don’t send the variable it won’t apply the filter

#

I tested it

#

and I removed the variable not the filter there

proven lantern
#

I bet I'm right

hushed robin
pale vessel
proven lantern
hushed robin
#

It works with just 2018 there

civic scroll
#

just read the docs

#

🤓

earnest phoenix
radiant kraken
#

even if you do it would be very inefficient to store methods in structs

earnest phoenix
#

"Inefficient"?

radiant kraken
#

you would have to store those method function pointers every time the struct is initialized

#

which wastes a lot of memory

earnest phoenix
#

That's not how it works, it the function makes sense to go with a struct then that is that, and note that it barely costs any memory as member functions are already optimized in a way that barely uses any memory

wheat mesa
#

Can I see what you mean by “member functions”

radiant kraken
#

member functions doesn't exist in C, no?

#

they are only a part of C++

radiant kraken
earnest phoenix
#

I'm talking about function pointers in structs, even though the C standard does not name them as member functions, they have quite the same concept going by their specification

wheat mesa
earnest phoenix
#

Correct

wheat mesa
#

But as for function pointers in structs, that does sound slightly wasteful since I would assume it’s 8 bytes for each pointer

wheat mesa
#

Unless it gets optimized down

radiant kraken
#

the only way to implement methods is just a function that accepts a pointer to the struct as an argument

wheat mesa
#

(Somehow)

radiant kraken
wheat mesa
#

Yeah C is the last language I would expect to have syntactic sugar

radiant kraken
#

you would rarely see things like something->function(arguments); in C

wheat mesa
#

From my limited time with OpenGL, it usually has you pass a pointer to the data you’re modifying in functions

radiant kraken
#

yes it does

#

void * my beloved

wheat mesa
#

Like glGenBuffers(&vbo, 0);

radiant kraken
#

windows API does a lot too

wheat mesa
#

Or whatever is meant to be the argument

earnest phoenix
# radiant kraken it doesn't

Yes it does, ever heard of alignment? The compilers are smart enough to optimize the size according to the alignment to make it use as less memory as possible, you can even modify the behavior of the optimization by using pragma directives like pack()

radiant kraken
#

even if you do it would look really ugly in C because unlike C++ you have to ```c
data.method(&data, arguments);

#

it's better to just do data_method(&data, arguments);, it also saves memory space since each function pointers occupies 8 bytes

earnest phoenix
# radiant kraken there's no point in storing methods as function pointers in C structs

Wrong

There are cases where storing them as such is preferred:

  1. Polymorphism: In object-oriented programming, polymorphism allows objects of different types to be treated as objects of a common base type, storing function pointers in a struct can allow you to implement polymorphism in C... by storing different function pointers that represent different behaviors in the struct, you can switch between different implementations of a function based on the object's type

  2. Callbacks: Callback functions are functions that are passed as arguments to other functions and are called later to perform some specific task, by storing a function pointer in a struct, you can specify a callback function that will be called at a specific point in the program execution

This allows for extensibility and customization in your code, as different callback functions can be provided by the caller, common examples of callbacks include event handlers in event-driven programming or comparison functions for sorting algorithms

  1. Interface abstraction: If you have a set of related functions that need to be used interchangeably, you can store their function pointers in a struct, this allows you to abstract away the specific implementations and provide a clean and consistent interface to other parts of your program

And we shouldn't talk about size or memory usage since they'll be optimized anyway so the general pointer sizes are fully reduced (to even a single byte because of the alignment information)

#

But sure, you can also go the other way as you suggested

radiant kraken
#

no C libraries i've seen implement polymorphism, or anything you have suggested, in C you would rarely see function pointers stored in structs, especially if they're meant to be methods (which is stupid)

lots of libraries implement things like this:

#

i'm not saying that function pointers are pointless, it's just pointless to store them in structs with the purpose of using them as methods

earnest phoenix
#

Just because you haven't seen it doesn't mean none of them uses it as such

#

But you do have a very valid suggestion over the one I did

radiant kraken
#

can you give me one example of one usage of a library that stores function pointers as methods?

#

because i don't see them apply in Windows C API, pthreads, etc.

radiant kraken
grim aspen
#

Idk if this was answered already but this is a result of a Unicode failure

radiant kraken
#

wndproc is merely just a callback that the OS calls whenever a window event fires

earnest phoenix
#

Almost, that ain't the case for all

#

So uh, yeah...

radiant kraken
#

the second sentence...

earnest phoenix
#

Libxml2:

#

This argument isn't going anywhere, though I did say that you've got a very valid suggestion over mine, and I provided proof that mine is used in quite a lot of places so there's no need to continue

radiant kraken
#

oh well

earnest phoenix
#

👍

neon leaf
#

how should I store very large ids? BigInt or VarChar?

radiant kraken
neon leaf
#

postgres

lyric mountain
#

which lang's gonna use it?

neon leaf
#

js

#

mostly

lyric mountain
#

varchar then

neon leaf
#

alr

lyric mountain
#

but how long are we talking?

neon leaf
#

stuff like discord ids, github user ids, google profile ids

lyric mountain
#

not long at all then, just outside integer range

#

use string yeah, it'll save u the trouble when using them

neon leaf
#

pretty long, no?

#

the last one is a google profile id

#

the first two are github

lyric mountain
#

nah

neon leaf
#

also do you know why I am not recieving a refresh token with googles oauth flow?

#

github doesnt need one I read

#

but google does since it includes an expires field

spark flint
#

iirc you have to make another request to get the refresh token

proven lantern
#

i'm working on two different matchmaking flows. one is a host/join flow and the other is join only. this is my current idea for the host/join matchmaking flow.

An admin creates a discord channel named something like Mario Kart Matchmaking.
An admin runs my bot command to create an embed message in the channel like this

#

Then when someone wants to "host" a match they click one of the options from the dropdown

#

once someone clicks a host option another embed message is added to the channel like this

#

once enough people are in the lobby the host can start

#

there's probably a simplier way to do this

#

right tim?

quartz kindle
#

wat

proven lantern
#

how would you do a host/join matchmaking flow?

quartz kindle
#

is the admin step necessary?

proven lantern
#

not really, there could be a /host command that each player has access to. but the buttons could be easier for people.

#

i actually have a /host command in my current version

quartz kindle
#

all the options from the admin command can be implemented by a /host command in a step-by-step manner with buttons

proven lantern
#

oh yeah

quartz kindle
#

ex user does /host

#

embed shows up with buttons/dropdowns to chose game type, number of players, etc...

#

the host embed could even be ephemeral if thats possible

proven lantern
#

oh yeah

quartz kindle
#

until the final button to open the room makes it a normal message

proven lantern
#

or the bot just posts a message to the channel

quartz kindle
#

idk whats the state of modals rn, but could also make something with modals

#

for configuring the room

proven lantern
#

what if the admin step still existed, but the options aren't passed to it. so players still click the button to host the match, but they go through the wizard flow thing

quartz kindle
#

could be yeah

hushed robin
#

why not make a website at this point

proven lantern
proven lantern
#

do these rating type descriptions make sense and does it make sense to track these? I was thinking about another FFA rating that tracks player ratings in matches with 6+ opponents. does that make sense?

sharp geyser
#

Why is this shit still happening man, I've already told nginx to use the proper SSL cert instead of my mailserver one

sharp geyser
#
server {
        listen 80;
        server_name *.aarondye.dev;
        return 301 https://$host$request_uri;
}

server {
        listen 443 ssl;

        ssl_certificate /etc/letsencrypt/live/aarondye.dev-0001/fullchain.pem;
        ssl_certificate_key /etc/letsencrypt/live/aarondye.dev-0001/privkey.pem;
        ssl_protocols TLSv1.2;
        ssl_ciphers HIGH:!aNULL:!MD5;

        root /home/misty/portfolio/dist;
        index index.html;

        server_name *.aarondye.dev;

        location / {
                try_files $uri /index.html;
        }
}

What is wrong with this nginx config

#

Cause at this point its either this or my cloudflare

sharp geyser
quartz kindle
#

pretty sure you cant do *.website.com

#

you have to specify every single subdomain

#

and make a cert for every single subdomain

#

unless you actually have a wildcard cert

#

which is not that common

#

my config is server_name website.com www.website.com api.website.com test.website.com;

#

for example

#

and the pem file contains certs for all those domains specifically

hushed robin
#

what’s a bot that’s never been made

proven lantern
#

alright Tim, what do you think about this headless matchmaking flow?

Same first two steps
An admin creates a Discord channel for matchmaking. something like Rocket League Matchmaking.
An admin runs my bot command and my bot returns an embed message like this

sharp geyser
#

Or it should be a wildcard cert

proven lantern
#

once enough people click join queue it creates a message that alerts all the players like this

quartz kindle
#

i cant find a single example of someone actually using *.website.com on nginx conf, but its supposed to work

solemn latch
quartz kindle
#

even with wildcard certs they always show with a single server_name

solemn latch
#

ah

quartz kindle
#

set it to dns only

sharp geyser
sharp geyser
#

Oh wait

sharp geyser
#

Okay so oddly enough if I do something.aarondye.dev it points to my portfolio

#

I think my nginx config is fucked at this point

quartz kindle
#

try server_name aarondye.dev *.aarondye.dev;

#

otherwise idk

#

maybe your ssl is fucked

#

try generating a regular ssl and using that instead

sharp geyser
hushed robin
#

just use a gmail

sharp geyser
#

Battleless if you aren’t providing help please be quiet

sharp geyser
#

Also regarding this how would I direct those subdomains to their proper locations such as aarondye.dev points to my portfolio and mail.aarondye.dev points to my mail server on the same vps

lyric mountain
sharp geyser
#

Wdym

lyric mountain
#

else it refuses to use it

sharp geyser
#

Oh?

sharp geyser
lyric mountain
sharp geyser
#

Alright I’ll look into it when I get home

hushed robin
#

I have the perfect bot idea

#

this will be legendary

#

I can’t say it now so people don’t steal but I will send my progress soon 🤩

hushed robin
#

this will make me $10000 dollars

lament rock
#

I did manage to get a really good looking result with another pfp

#

@pale vessel ?

fossil bone
#

so anyway i thought i'd request a dev badge but somehow my bot got it instead

hushed robin
#

that’s not the active bot dev badge

#

that’s the badge bots get for registering a global slash command

sharp geyser
slender wagon
grim aspen
fossil bone
dreamy badger
#

Why is my bots profile picture on top.gg default?

deft wolf
#

You need to refresh it with "refresh data" button

#

Then click "edit" and "save"

earnest phoenix
#

Though I'm not sure if that'll work for you

long tundra
#

Hello I have Bot live on Topgg Website. Because of some accident I lost the discord account of that bot. So can you remove that bot from the website?

sharp geyser
#

@earnest phoenix Do you know anything about nginx? I have a question regarding on how it works internally, because i've seen multiple people do server blocks listening on the same port, for example both listen to 80 and it seems to work perfectly fine? Is this normal?

lyric mountain
#

The first frame is usually the static background of the gif, with the remaining frames being composed on top of it

sharp geyser
#

hello haku

lyric mountain
#

Hello there

sharp geyser
#

Do you know anything about nginx

lyric mountain
#

Depends on the question

lyric mountain
#

I do use it for my bot's apis

sharp geyser
#

I am mainly just wondering why its possible for two server blocks to listen on the same port

lyric mountain
#

You can use the same port as long as the address is different

sharp geyser
#

address being the server_name?

lyric mountain
#

So if u have 2 domains it'll work even if the ip is equal

#

Yes

#

Think about it as a combination of name + port

sharp geyser
#

so I could have?

server {
  listen 443 ssl;
  listen [::]:443 ssl;
  
  server_name aarondye.dev;
}

server {
  listen 443 ssl;
  listen [::]:443 ssl;

  server_name mail.aarondye.dev;
}
lyric mountain
#

For example I have shirojbot.site and api.shirojbot.site

sharp geyser
#

had I known this i think my issues would of been solved long long ago

lyric mountain
#

U should add a port 80 redirect tho

#

So if someone tries to access with http it redirects to https

sharp geyser
#

Oh?

#

Ah

rustic nova
#

unless you have it behind cloudflare

#

then make sure it doesnt redirect

#

hit that wall before KEKW

lyric mountain
#

It works even with cloud

sharp geyser
#

so something like this?

lyric mountain
#

I use it personally

rustic nova
#

had it infinitely loop within cloudflare when redirecting to 443

#

can be a apache2 skill issue tho ngl

lyric mountain
#

Lmao

lyric mountain
sharp geyser
#

my 80 one redirects back to a https version of the site

lyric mountain
#

Would need to check my config to be sure

sharp geyser
#

Alright then question real quick

#

Do I need to make a redirect for each domain/subdomain, so one for aarondye.dev and one for mail.aarondye.dev or can I combine them into the same one?

lyric mountain
#

You can overwrite only the port and keep the address unchanged

sharp geyser
#

wdym

earnest phoenix
lyric mountain
sharp geyser
#

that makes my life so much easier

#

Do you use letsencrypt for your ssl certs?

lyric mountain
#

Don't remember, but I use cloudflare origin ssl

sharp geyser
#

Mmm

#

I was just curious as to how I should gen my ssl certs with letsencrypt

#

cause I know it gives you the options of giving it multiple domains but seperating them by commas, I assume thats so you can do aarondye.dev,mail.aarondye.dev,someothersubdomain.aarondye.dev

#

and have all your subdomains covered

lyric mountain
#

Using cf has the advantage of hiding the true ip and acting as a layer against ddos

#

The cert also works with any subdomain iirc

sharp geyser
#

How would I use cf for this?

lyric mountain
#

Don't remember adding socket and api domains to it

sharp geyser
#

Just proxy it through cloudflare?

lyric mountain
#

You point your domain do cf and point cf to the ip

#

There's a tutorial for it on their page

#

Just search cloudflare origin ssl

sharp geyser
lyric mountain
#

I think so

#

Can't really get it wrong if it's an official guide

sharp geyser
#

As long as it is about Origin CA certs im sure its the right thing

#

just wanna be sure before I fuck something up unknowingly or do something useless

lyric mountain
#

I mean, in any case reverting to the original state is just pointing the domain to to the ip

#

Just save your current config in case u need to revert

#

Or comment the cert line, as that's the only thing you'll change

sharp geyser
#

bro this shit is so confusing when you are as tired as I am

lyric mountain
#

Best to attempt it with a clear mind, it's not hard but there are a few steps here and there

sharp geyser
#

Well I saved the cert to a pem file and the key to a key file

#

I guess now i just move those over to my vps and have nginx grab those in the ssl_certificate and ssl_certificate_key props

lyric mountain
#

Do note, origin certs aren't valid if ur not using cloudflare

sharp geyser
#

I am using cloudflare

lyric mountain
#

So only switch to them once u finish configuring everything

#

Ah ok

sharp geyser
#

Ye

#

Should I proxy everything through cloudflare after or just dns only?

#

although pretty sure my mail server doesn't like being proxied so I will have to use dns only

lyric mountain
#

There's a config for emails on cf iirc

sharp geyser
#

oh?

lyric mountain
sharp geyser
#

ty

#

gotta figure out hwere I wanna put my pem and key file tho

#

dk what would be the best location

#

honestly might just put it in my home dir

lyric mountain
#

The two cert folders

#

There're two folders specifically for certs

sharp geyser
#

ye its in /etc/ssl right?

lyric mountain
#

Yes

sharp geyser
#

for some reason I can't really access those

lyric mountain
#

Are u root?

sharp geyser
#

I am doing it through my user rn

#

I don't allow login on root on my vps

lyric mountain
#

Only root have access to them

#

U can sudo into it

#

Or su -iu root

sharp geyser
#

I am doing this through WinSCP as I don't really know how to get it onto my vps through the terminal

lyric mountain
#

Which will switch to root user if ur already logged in

rustic nova
#

login as user

#

sudo su root

#

ez

sharp geyser
#

ye I know that

#

but I have no idea how to get the key and pem file onto the vps simply through the terminal

#

I guess I could just copy the contents and make a new file using nano

lyric mountain
#

Scp "from" "to"

#

For example scp C:\users\blabla\desktop\somefile.txt user@123.12.23.100:1234:/folder

sharp geyser
#

I am confused 😔

#

I swapped to using the origin ca cert and its giving me site error

#

ugh

#

What am I doing wrong

#

@lyric mountain does nginx just hate me?

#

Is it my fucking dns records?

#

At this point idfk

lyric mountain
#

Did u make the domain point to nginx?

sharp geyser
#

my dns records point to the server nginx is on

lyric mountain
#

Yes, but what abt the domain itself?

sharp geyser
#

wdym

lyric mountain
#

Aaron thing, it must point to cloudflare else ur just ignoring it entirely

sharp geyser
#

I don't get what you mean tho.......

lyric mountain
#

The same place u get the origin ca, there are instructions to it

sharp geyser
#

haku I quite literally don't get what you mean

lyric mountain
#

Just a sec

sharp geyser
#

if you mean the nameservers of the domain then yes its using cloudflares nameservers

rustic nova
#

boldly stated question

#

why is typescript annoying me

#

and nitpicking about issues

lyric mountain
#

Because the type declaration is weird

rustic nova
#

i hate it

#

literally that wall of bricks trying to use svelte right now

#

like pls

lyric mountain
#

ConstructorOfASvelteComponent lmao

sharp geyser
#

and honestly kinda getting too annoyed to keep messing with it

lyric mountain
#

Also idk if this matters, but i have mine with proxy enabled

#

Might be it

sharp geyser
#

Doesn't seem to be

#

This is getting rather annoying

lyric mountain
#

Once I'm in my pc I'll check how my settings are configured

sharp geyser
#

I mean even following that guide didn't help so I think im just fucked ngl

lyric mountain
#

The good thing is that u never need to touch it ever again once it's done

#

I'll check later my domain and cf settings to be able to help u troubleshooting it

sharp geyser
#

Bro

#

Guess what the issue was

lyric mountain
#

What?

#

Cache?

sharp geyser
#

my server block for port 80

#

💀

lyric mountain
#

Lmao

sharp geyser
#

and the cache ye

#

letting cloudflare handle the redirect for https is the solution ig

#

lets fucking go man

lyric mountain
#

Ah so u blocked 80 on the firewall

sharp geyser
#

nah 80 is open

#

and allowed

#

idk what was going on

lyric mountain
#

Then nginx should've redirected it, but it worked nonetheless

sharp geyser
#

Now lets see if I can setup my mailserver with nginx without fucking shit up

#

Before I had the issue of my portfolio conflicting with the mail server

#

Fuck me man

#

😔

sharp geyser
#

aarondye.dev should be my portfolio tho

lyric mountain
#

U messed something then

sharp geyser
#

mailcow nginx conf

#

aarondye.dev nginx conf

#

I assume im supposed to use the same cert for all server blocks that still use the same domain even if its a subdomain of that domain

#

im slowly losing my mind

lyric mountain
#

My configs for example

sharp geyser
#

should I change the ports they listen on?

#

you seem to do so

lyric mountain
#

I have different apis running on different ports, iirc if u don't specify any it'll default to 80/443

sharp geyser
#

ugh why is this so fucking confusing

lyric mountain
#

Here's the one for the site itself

sharp geyser
#

I might just hire someone to do this for me at this point

#

Because I simply just don't understand

lyric mountain
#

Don't give up, u can do it

sharp geyser
#

bro i've been at this for months

#

Nothing I do is working how I want it

lyric mountain
#

Compare my configs with yours, try slowly making it similar until it works, to see why it isn't

sharp geyser
#

I mean mine are virtually the same

lyric mountain
#

Also check if u didn't point both domains to the same address on cf

sharp geyser
#

this is my current dns config

lyric mountain
#

Tbh it shouldn't matter, as it's ginx who'll redirect

#

Also restart nginx in case u didn't, do nginx -t to see if there's any syntax error

sharp geyser
#

ye I already restarted nginx

lyric mountain
#

Try specifying the port

sharp geyser
#

there is no port for my portfolio

#

its a static website

lyric mountain
#

It's 443 then

#

Or 80

sharp geyser
#

it all just points to my mailserver

#

No matter what I do it ends up at the mailcow ui

lyric mountain
#

Soon I'll be on my pc, then it'll be easier to read

sharp geyser
#

Alright well lmk when you can cause your help would be much appreciated

#

I gotta head to the UPS store rn anyway

nocturne falcon
#

hey 👋 i am making a security module for my bot but when i tested creating channels it was just too slow to take action in both banning the executor & deleting the spam created channels (for ex: 50 channels in 30 seconds). can someone suggest me ideas to speed up the process?

lyric mountain
#

You can't if you're deleting channels

#

You're being ratelimited

#

The best way would be to lower what your bot considers a channel spam so it detects earlier

#

Like creating 5 channels too quickly

#

Idk if such feature would be useful at all, as if a bot got perm to create channels the issue is with server management

#

@sharp geyser one last question, where did u put ur config files?

nocturne falcon
lyric mountain
#

A person would never trigger it, as discord client limits how fast u can delete stuff

#

Same for creating

#

So you'd exclusively detect bots or selfbots

#

If either reached a position with enough power to do it, then the server management is at fault

sharp geyser
nocturne falcon
lyric mountain
sharp geyser
#

nothing in conf.d and oddly enough my aarondye.dev conf is missing from sites-enabled

lyric mountain
#

U can't really prevent stupid mods

sharp geyser
#

did I forgor to symlink it thinkEGG

lyric mountain
#

Put your site in sites-enables and the mail in conf.d

#

I mean, don't copy to sites-enabled

#

Symlink it

#

But do copy mailcow to conf.d

sharp geyser
#

why put the mail in conf.d?

nocturne falcon
lyric mountain
#

That's for apis or non-site configs

sharp geyser
#

ah

lyric mountain
sharp geyser
#

so do I just like cp /etc/nginx/sites-enabled/mailcow /etc/nginx/conf.d?

lyric mountain
#

Then see if the distance between them is low enough

sharp geyser
#

ah

lyric mountain
#

Sites-available is not considered when setting nginx

sharp geyser
#

so I don't even need it in sites-available either then?

lyric mountain
#

It's like a bench for site configs

nocturne falcon
lyric mountain
#

So u can enable/disable sites easily by creating/deleting tge symlink without losing the file

sharp geyser
#

I see

lyric mountain
#

How are u doing it currently?

sharp geyser
#

so I can delete the mailcow conf from sites-available then and only update the one in conf.d when I need to ?

lyric mountain
#

Mv for move

#

The only 2 folders considered for nginx are conf.d and sites-enabled

sharp geyser
#

I think I accidentally moved the one in the sites-enabled

nocturne falcon
# lyric mountain Wdym?

means if any bot create 20 channels in one minute but the bot will detect it after this number of channels which is slow , i want to know what i will do for fast result

sharp geyser
#

yea I did

#

is that a problem?

lyric mountain
#

Lmao but u kept the original file right?

sharp geyser
#

👀

#

no

lyric mountain
#

...

#

Well, at least u sent a print here

#

A symlink is useless without the source

sharp geyser
#

well I have the file backed up somewhere else

lyric mountain
sharp geyser
nocturne falcon
lyric mountain
#

It should be:
/etc/nginx/conf.d/mailcow
/etc/nginx/sites-available/site
sym /etc/nginx/sites-enabled/site

sharp geyser
#

Okay so I am good then

#

I can delete the mailcow in the sites-available and leave a copy of it in conf.d

lyric mountain
#

Now do nginx -t

#

Yes

#

If the test says ok, u can restart nginx

lyric mountain
#

How are u detecting a channel spam is happening?

#

The code I mean

nocturne falcon
lyric mountain
#

The simplest step would be to ban any bot invited with admin perm

sharp geyser
#

😩

lyric mountain
#

As a nuke is useless without it

sharp geyser
#

god damnit

nocturne falcon
lyric mountain
sharp geyser
#

Yea but I don't get how

lyric mountain
#

Did nginx -t say anything?

sharp geyser
#

Nope

#

it said all was a ok

nocturne falcon
#

action speed is slow

#

@lyric mountain

lyric mountain
#

Show your current code for detection

lyric mountain
#

It's supoosed to error as the site is not mapped on nginx

sharp geyser
#

Are you sure it even looks at conf.d ?

lyric mountain
#

If it DOES redirect u to the portfolio then u have a duplicate somewhere

lyric mountain
sharp geyser
#

cause I just remembered that when running nginx -t it should of errored

#

cause I no longer have /etc/letsencrypt/live/aarondye.dev/fullchain.pem

#

but that was included in the file (forgor to remove it)

lyric mountain
#

It's how I have my site set up

sharp geyser
#

weird

nocturne falcon
sharp geyser
#

for some reason I dont think nginx is actually registering the mailcow file

lyric mountain
#

Put the cow somewhere else, to see if u can still access the site

#

You're not supposed to be able to, because nginx can't find the config for it anymore

sharp geyser
#

Okay another blunder on my part

#

apparently its important to suffix the file with .conf in conf.d

lyric mountain
#

A

sharp geyser
#

Listen man I thought nginx would be fine with it being how it normally is with no file extension

#

😔

#

Haku you will forever be a god in my eyes

#

you are on par with tim rn

#

you solved my months of pain in a matter of hours

#

and now i understand a bit more of how nginx works

nocturne falcon
#
client.on('channelCreate', async (channel) => {
    const guild = await client._guilds.get(channel.guildId);
    const audit = await channel.guild.fetchAuditLogs({ limit: 2, type: AuditLogEvent.ChannelCreate });
    const logs = audit.entries.first();

    if (logs.executorId === channel.guild.ownerId) return;
    if (logs.executorId === client.user.id) return;
    if (guild) {
        if (guild.authorized.includes(logs.executorId) || guild.admins.includes(logs.executorId)) return;
    }

    await channel.guild.members.ban(logs.executor, { reason: 'Synthia Protection Shield' });
    const mod_log = await channel.guild.channels.fetch(guild.reports);

    if (!mod_log) return;
    await mod_log.send({ embeds: [client.utils.embed(channel).setDescription(bold(`${logs.executor.username} has been banned for creating channels.`))] });
    await channel.delete('Synthia Protection Shield').catch(() => null);
});

@lyric mountain

lyric mountain
#

Actually, u made me something wonder something

sharp geyser
#

oh?

lyric mountain
#

I was wrong using conf.d for the api 💀

sharp geyser
#

lol

lyric mountain
#

Just searched it, it's supposed to be for literal configs

#

Gonna move my api to sites available too

#

But well, easy thing to fix

sharp geyser
#

finally don't have a fucked nginx

lyric mountain
#

Yw

sharp geyser
lyric mountain
#

It's for detecting channel spam

sharp geyser
#

oh I see

lyric mountain
#

But I cant read it until I'm at pc

sharp geyser
#

why not let auto mod do that?

lyric mountain
#

Cuz mobile wrecks code

nocturne falcon
sharp geyser
#

him not at pc

#

him cant read code

nocturne falcon
#

i am also on phone bro

sharp geyser
#

if you do wanna help haku

lyric mountain
#

Oh, ur using audit logs

#

U should track it locally, else you'll make too many requests for fetching it

#

Idk how to explain how tho

#

Basically have a list of when the channelCreate events happened, and by who

#

Then every time one is created, check the last N entries and see if the time between them is too low

rustic nova
sharp geyser
nocturne falcon
sharp geyser
#

I think you need to get your eyes checked

rustic nova
#

stinky clientum mods

#

or whats that

#

smh

earnest phoenix
lyric mountain
#

Nice, now it's all ok

lyric mountain
nocturne falcon
lyric mountain
#

Not really, you're already receiving those events from discord

#

It all depends on how you implement the comparison of entries

nocturne falcon
earnest phoenix
lyric mountain
lyric mountain
#

A list of this would have enough info for tracking spams

earnest phoenix
#

hmm

lyric mountain
#

After that just keep the last N entries

#

To prevent flooding the list with old data

#

Optionally use a TTL library

#

Like expiring-map

earnest phoenix
#

well for some odd reasons guildAuditLogEntryCreate isnt being triggered but maybe ill ask it at discord.js

lyric mountain
#

Did u include the intent?

earnest phoenix
#

is there a extra specific intent for it?

lyric mountain
#

I think so

sage bobcat
#

One message removed from a suspended account.

earnest phoenix
#

Guild is the basic intent you need for the bot to work

lyric mountain
#

Check the available intents, see if any mention audit logs

earnest phoenix
#

i already have those intents: ["Guilds", "GuildMessages", "GuildMembers", "MessageContent", "DirectMessages"],

lyric mountain
#

There are constants for that yk

sharp geyser
#

I think you need GuildModeration intent to receive any audit log related events

#

unless I am reading it wrong

lyric mountain
#

That's likely it

earnest phoenix
#

ah

lyric mountain
#

U need to keep the first

#

For disposition of type replace If it was optimized u always need to keep the first frame (aka background frame)

#

Actually for both u need to keep

#

It all depends on whether the gif was optimized (removed pixels that never change) or not

#

It's safe to always keep it regardless, if it wasn't optimized it'll simply be overlayed anyway

proven lantern
#

any reason to use Set over an object literal here? seems like converting the array into a set would be slower than just using an object.

#

i will write speed tests faster than tim

#

object literals win

#

couldn't Set be optimized so it's at least as fast as object literals?

earnest phoenix
# proven lantern couldn't Set be optimized so it's at least as fast as object literals?

You do realize that Sets have more overhead compared to objects literals right? Sets checks for values thoroughly and rejects duplicate values meanwhile that's not the case for object literals at all, and besides, when even checking for a value yourself you're calling a method on a Set, but accessing a property in an object literal which is obviously a lot faster

proven lantern
#

so the real purpose for Set is that they can compare object literals

quartz kindle
#

@earnest phoenix yo is there any way to make gcc log which compiler flags were used? or anyway to check if for example lto was enabled or disabled, as well as O2 or O3 for example

#

in the build logs

proven lantern
#

couldn't Sets be optimized to ignore the extra overhead stuff if all the keys are strings?

earnest phoenix
proven lantern
quartz kindle
#

tried verbose, doesnt show anything

earnest phoenix
#

Then you can do:

$ npm_config_verbose=1 CFLAGS='-v' CXXFLAGS='-v' <your npm command or whatever>
quartz kindle
#

works ty

earnest phoenix
#

You're welcome

quartz kindle
# earnest phoenix You're welcome
COLLECT_GCC_OPTIONS='-o' 'Release/obj.target/swisseph/swisseph/swecl.o' '-D' 'NODE_GYP_MODULE_NAME=swisseph' '-D' 'USING_UV_SHARED=1' '-D' 'USING_V8_SHARED=1' '-D' 'V8_DEPRECATION_WARNINGS=1' '-D' 'V8_DEPRECATION_WARNINGS' '-D' 'V8_IMMINENT_DEPRECATION_WARNINGS' '-D' '_GLIBCXX_USE_CXX11_ABI=1' '-D' '_LARGEFILE_SOURCE' '-D' '_FILE_OFFSET_BITS=64' '-D' '__STDC_FORMAT_MACROS' '-D' 'OPENSSL_NO_PINSHARED' '-D' 'OPENSSL_THREADS' '-I' '/root/.cache/node-gyp/20.3.0/include/node' '-I' '/root/.cache/node-gyp/20.3.0/src' '-I' '/root/.cache/node-gyp/20.3.0/deps/openssl/config' '-I' '/root/.cache/node-gyp/20.3.0/deps/openssl/openssl/include' '-I' '/root/.cache/node-gyp/20.3.0/deps/uv/include' '-I' '/root/.cache/node-gyp/20.3.0/deps/zlib' '-I' '/root/.cache/node-gyp/20.3.0/deps/v8/include' '-fPIC' '-pthread' '-Wextra' '-Wno-unused-parameter' '-m64' '-O3' '-fno-omit-frame-pointer' '-MMD' '-MF' './Release/.deps/Release/obj.target/swisseph/swisseph/swecl.o.d.raw' '-Wall' '-v' '-c' '-mtune=generic' '-march=x86-64'
``` does this mean its already using -O3 even though i didnt specify it?
earnest phoenix
#

Yes

quartz kindle
#

oh, no wonder i didnt see any performance difference when compiling with CFLAGS O3

earnest phoenix
#

node-gyp specifies the -O3 CLI flag when the build type is Release which is the default anyway

quartz kindle
#

i see

proven lantern
#

i was thinking the Set class could check for any objects and if there are none just fallback to using a normal object literal. but then once an object is added you'd need to copy everything from the object literal into a new storage format

quartz kindle
earnest phoenix
#

The compiler infers the architecture of the host machine by default so you don't have to specify it

quartz kindle
#

👍

earnest phoenix
#

Also if you're looking for better performance, use the Clang compiler :^)

proven lantern
#

this is what i came up with, but it adds an extra loop over the array

quartz kindle
#

on node-gyp + linux

distant harness
#

Hello ! Someone can help me please ? I would to center my bio who is in HTML/CSS, adapt it for phone and enlarge the frame.

earnest phoenix
quartz kindle
#

debian

quartz kindle
#

12 i thikn

distant harness
quartz kindle
#

ah i think i got it

#
export CC=/path/to/clang
export CXX=/path/to/clang++
export GYP_DEFINES="clang=1"
lyric mountain
hushed robin
#

he wants to center it

distant harness
distant harness
lyric mountain
#

well, use markdown instead of html

earnest phoenix
quartz kindle
#

rather than starting with something with a ton of preinstalled stuff

proven lantern
#

i have linux on my windows

earnest phoenix
#

Well Debian's repositories are incredibly outdated so there's also that, unless you're using the unstable repository

quartz kindle
#

i usually install from alternative repos or build from source

#

depending on the thing

distant harness
lyric mountain
#

they don't mind

earnest phoenix
quartz kindle
#

clang is part of llvm?

distant harness
quartz kindle
#

oh

lyric mountain
#

the description was supposed to be centered already

#

are you changing the width of it?

earnest phoenix
distant harness
#

you want to see my code ?

lyric mountain
#

sure

quartz kindle
#

so, did llvm make clang or did clang make llvm

#

:^)

earnest phoenix
distant harness
# lyric mountain sure
<!DOCTYPE html>
<html>
  <head>
<style type="text/css">

@import url('https://fonts.googleapis.com/css2?family=Lexend&display=swap');

    body {
        background-color: white;
    }

    h1.title1 {
        color: #FFCC00;
        font-family: 'Lexend';
        font-weight : bold;
        text-align: center;
    }

    div.arrondi {
        border-radius: 10px;
        width: 450px;
        padding: 10px;
        background: #0A0019;
    }
    p.para {
        color: #FFCC00;
        font-family: 'Lexend';
        font-weight: normal;
    }

    h2.bot {
        color:#FFCC00;
        font-family: 'Lexend';
        font-weight: normal;
        text-align: center;
    }

    p.bref {
        color:#FFCC00;
        font-family: 'Lexend';
        font-weight: normal;
        font-size: 15px;
        text-align: center;
        margin-top: 20px;

    }

    </style>       
    <title>Page 1</title>
  </head>
  <body>
    <div class="arrondi">
    <h1 class="title1">QU'EST CE QUE WWD® ?</h1>
    <p class="para">WWD® est un bot Discord créé en 2019. Il a pour utilité de vous aider dans la modération ainsi que l'administration de votre serveur.<br><br>Pour le présenter brièvement c'est un bot qui :<br>・N'a pas besoin d'un panel pour être géré<br>・Est connecté 24h/24 et 7j/7<br>・Est utilisé pour une utilisation simple pour un résultat de qualité<br>・100% gratuit<br><br>En terme de fonctionnalités, WWD® saura répondre à vos demandes grâce à ses commandes basiques de modération (ban, kick, warn...), ses commandes d'administration (ticket, userinfo, giveaway...) et quelques commandes fun (8ball, cookie...).<br>Des commandes de jeux sont prévues et en cours de développement.</p>
    <p class="bref">bref.</p>
    <h2 class="bot">C'EST LE BOT QUI VOUS FAUT.</h2>
    </div>
</body>
</html>```
#

to adapt on top gg, ive remove doctype html, html, head

lyric mountain
#

don't use <html>, <body> or <head>

#

they dont work properly on topgg

hushed robin
distant harness
lyric mountain
#

simply remove those tags and it should work right away

#

also <title> wont work either

distant harness
#

its do

lyric mountain
#

do?

distant harness
#

i have remove this tags

distant harness
lyric mountain
#

yes

#

simply removing it should work

distant harness
distant harness
earnest phoenix
#

@quartz kindle how did it go?

distant harness
#

*good

#

so i have to put at the beginning [center] and at the end [/center] ?

lyric mountain
#

<center> u mean

distant harness
#

ok

lyric mountain
#

u could try text-align: center too

quartz kindle
earnest phoenix
#

For example, clang-16 for LLVM v16

distant harness
#

@lyric mountain :/

earnest phoenix
#

You can install a symlink to use it as clang for example

lyric mountain
#

if you want the yellow text use color: orange on the text div

distant harness
#
<center>
<style type="text/css">

@import url('https://fonts.googleapis.com/css2?family=Lexend&display=swap');

    body {
        background-color: white;
    }

    h1.title1 {
        color: #FFCC00;
        font-family: 'Lexend';
        font-weight : bold;
        text-align: center;
    }

    div.arrondi {
        border-radius: 10px;
        width: 450px;
        padding: 10px;
        background: #0A0019;
    }
    p.para {
        color: #FFCC00;
        font-family: 'Lexend';
        font-weight: normal;
    }

    h2.bot {
        color:#FFCC00;
        font-family: 'Lexend';
        font-weight: normal;
        text-align: center;
    }

    p.bref {
        color:#FFCC00;
        font-family: 'Lexend';
        font-weight: normal;
        font-size: 15px;
        text-align: center;
        margin-top: 20px;

    }

    </style>       
    <div class="arrondi">
    <h1 class="title1">QU'EST CE QUE WWD® ?</h1>
    <p class="para">WWD® est un bot Discord créé en 2019. Il a pour utilité de vous aider dans la modération ainsi que l'administration de votre serveur.<br><br>Pour le présenter brièvement c'est un bot qui :<br>・N'a pas besoin d'un panel pour être géré<br>・Est connecté 24h/24 et 7j/7<br>・Est utilisé pour une utilisation simple pour un résultat de qualité<br>・100% gratuit<br><br>En terme de fonctionnalités, WWD® saura répondre à vos demandes grâce à ses commandes basiques de modération (ban, kick, warn...), ses commandes d'administration (ticket, userinfo, giveaway...) et quelques commandes fun (8ball, cookie...).<br>Des commandes de jeux sont prévues et en cours de développement.</p>
    <p class="bref">bref.</p>
    <h2 class="bot">C'EST LE BOT QUI VOUS FAUT.</h2>
    </div>
</center>```
#

i have put this

earnest phoenix
#

@quartz kindle ^

#

And if you want to set Clang as the default compiler you can run:

$ update-alternatives --install /usr/bin/cc cc /usr/bin/clang 100
$ update-alternatives --install /usr/bin/c++ c++ /usr/bin/clang++ 100
proven lantern
#
    div.arrondi {
        border-radius: 10px;
        width: 450px;
        padding: 10px;
        background: #0A0019;
    }
#

the width here is probably the issue

earnest phoenix
earnest phoenix
quartz kindle
earnest phoenix
#

That's understandable

#

You can set the CC AND CXX environment variables to specify the compiler to use

proven lantern
#

make sure to never use the LTO option. stick with defaults

quartz kindle
#

users complained it wouldnt build on amazon aws

earnest phoenix
#

LTO is very good, keep it on

quartz kindle
#

i had to remove it tho

proven lantern
quartz kindle
#

yeah

#

we went through this with voltrex

#

turns out amazon linux puts the lto plugins in a different directory

#

for some reason

earnest phoenix
#

Because the stupid Amazon Linux distributions don't install the LTO plugins to a standard directory, it's so incredibly annoying

#

What the hell were they thinking

proven lantern
#

saving cpu usage on their servers at the expense of everyone else

#

smart

earnest phoenix
#

I think the Amazon Linux distributions are the only distributions that installs them to a non-standard directory

proven lantern
#

the aws instances that are building stuff will use less cpu cycles to build and everyone that uses the software will use more cpu cycles

#

might be joking though

quartz kindle
#

they did it so their corporate users are forced to hire amazon management plans to manage it for them

earnest phoenix
#

🔥💯

quartz kindle
#

probably because i have to use a different lto like you said

#

but anyways, performance difference is negligible

#

probbaly because node/napi is the bottleneck in my case :^)