#development
1 messages ยท Page 54 of 1
@vestal glen What's the purpose of a Dockerfile? Is it just there for automation?
you use dockerfiles to automate it over and over again
they're self-documentating ways of deploying applications
conistently doing docker run is an imperative approach
while using dockerfiles is a declarative approach
using docker run to deploy multiple applications (eg a service) is very cumbersome
let's say you want to deploy nextcloud, mariadb, and redis
you now have to type docker run 3 times and in the command line you have to specify the relation of each service to each other
(you get very long docker run commands)
or you can create a docker-compose file
and do docker-compose up -d
which is the equiavlient
you can't save docker runs, docker-compose is just an all round better imo
documentation, less cumbersome, etc.
That makes sense
Dockerfiles are to describe the environment that should run in your container.
and a dockerfile is used to actually build a specific container
Thanks for the explanation
I also had a question about Ghost: is it viable for sites other than blogs? From first glance (haven't dug too deep yet) it seems that it's centered heavily around posts
it is centered around content that can be represented by posts, similar to wordpress, yes. But I believe it also supports entries without a date, so "pages". Not sure how well, though.
since when does CPP let you have multiple strings as a single variable thingo
also, how does visual studio let me make microsoft sql databases for free, I thought it cost money?
like it lets me create a .MDF to connect to, isnt microsoft's sql premium tho?

local databases are free???
Iirc MDF are not actual database
Visual studio ofc allows you to connect to SQL server
But Im not sure if Vs has built in SQL server

Doubt that
Cause even oracle express edition is MB in size
Tldr: not lightweight enough to be included in the ide
@vestal glen It seems that Ghost doesn't have form builders outside of manually implementing third party plugins, so should we learn HTML/CSS/JS and Node.js and stick with Ghost, or is it better to build a site from scratch
ghost is a giant self-buliding website
you can use templates and their built in content management system
you can integrate HTML/CSS inline if you want something unique though
@nocturne crypt Are there templates than can be used without a CMS?
And is forgoing a CMS cumbersome?
with ghost you can enable js and html5 directly into the pages if you want
you don't need something like ghost to write a website
it's just less annoying
Thanks for the info Phoenix! I guess I'll just keep playing around with Ghost and start learning HTML and CSS in the meantime
it's always cool to integrate both
did it just create a database for me?
where
database is not a random file (looking at you sql lite)
it requires special drivers or another software (sql servers)
https://www.udemy.com/course/python-crash-course-for-beginners-l/?couponCode=A918B5BF4E9C3124D081
In case anyone needs it
finally put some work on
since when does CPP let you have multiple strings as a single variable thingo
@nocturne galleon since forever
and it's not multiple strings it's one string concatenated

Oooh
Just starting to use Blazor Web Assembly and am not sure how i should structure the project. Should the Blazor app talk directly to a database or make calls to an external API?
and it's not multiple strings it's one string concatenated
@round dome Would'nt the null characters break up the strings?
No the compiler doesn't concat the strings' null bytes wtf

I was thinking that the string literals would have the null character added to each one. But it turns out that the compiler concatenates the string literals that are seperated by only white space before adding the null character.
i'm going to instantly regret asking this question in this discord
but does anyone know the way of using tensor cores in Cuda?
anyone?
@nocturne galleon its concatinating them at compile time, which is nice for multi-line strings
Can anyone help out with this? https://stackoverflow.com/questions/64225757
I've been stuck with it for ages
You using tensorflow for mixed precision?
Tensor API is very poorly documented
https://docs.nvidia.com/cuda/cuda-samples/index.html#cuda-tensor-core-gemm
There is some info here
The reference guide for the CUDA Samples.
This PDF has "some" information, whether it can be counted as useful is up for debate
@nocturne crypt
i finally got the dockers to use my 2060
i wanna figure out what the fuss is over these tensor cores
The API docs are so sparse they might as well have not bothered
okay
so i figured it out
tensor cores are microcode optimizations for the GPU
there's nothing to program against, just setup the code to take advantage
oh boy
LOL
Didn't realise this channel was here - anyone know their way around CSS that can look at a page and tell me while a style isn't being found even though it's defined in a .scss ?
have you looked at the compiled CSS ?
That was, in fact, what the problem was. I thought it was auto-compiling it - it was not.
you need a CSS Preprocessor to process SCSS
not sure what your application context is
but pretty sure in node, webpack takes care of this
yeah, i thougth bootstrap was handling it - it wasn't.
needed to be generated manually.
webpack handles it provided you have the correct loader, which is sass-loader:
https://webpack.js.org/loaders/sass-loader/
as long as it has the file ending in .scss or .sass (regex in test) it'll automatically use the loaders listed under 'use'.
That or transpile it manually
Thanks @tulip oracle
I'm new to nodejs, using it at work since 2 weeks
typescript shiver
<-- die hard java guy
lol, my knowledge is literally based on me making one single website using React, babel....plus a shit ton of other webpack shit
Mostly JavaEE based applications
I'm more of a backend guy anyways haha
Yep lol
I started with C#
then moved onto Java
I use C for embedded applications, or when Java doesn't cut it
I've written applications that use JNI before
- Create java interface, declare methods with
nativekeyword
- use
$ javahto generate headers for said interface
- Implement header in C
- Compile
- Load
.sofile withSystem.loadLibrary()
OpenCV mmmm
yeeee
ultimately, I scrapped that project module
and went with OpenALPR
because it did exactly what we needed
@tulip oracle 1 business customer, two groups of students, competing for the best solution to the problem
we won.
xD
nice
It was supposed to be an app for a bank, so you could enter license plate of a used car, the app would calculate the monthly fees if you took out a loan
using your financials on the phone, (not in the cloud)
only thing the cloud service did was take images and return car information from a centralized DB
the competing group, implemented a wearable (smartwatch) with a microphone you could talk to for the license plate
but our solution: snap a pic and get result within 1 second...
was superior
Yea ease of use
@tulip oracle we also made a concept to expand upon this with BLE
so a dealership with used cars, can have a bluetooth beacon in the little informational sign
and if you walk up to the car, all you have to do is look at your watch (we had a smartwatch too)
and it automatically senses the nearest beacon, and pulls car data from a database
Man that sounds hard to implement
though we ran out of time to fully realize this
it was possible
we did research and had proof of concepts
BLE has an accuracy of 1-2 meters
that was a fun project.
Were you guys using arduino?
android
Or had a proper guy who knew electronics/hardware and was planning on designing the pcb as well
Oh I was referring to the BLE beacon type
Bluetooth beacons can be bought straight up
they look like a big coin
send out their ID every second
for 3-4 years
until battery is dead
Oh yea no need to make your own BLE beacon hah
They're pretty much like longer range RFID cards
clear line of sight
you can do 30-50 meters
first time I use BLE
was to develop a navigation system for a planet without GPS
drop beacons in a pattern across the plane
you can triangulate your position
You would need heaps of those BLE coins to make it worthwhile hah
@tulip oracle if you were to actually deploy this
BLE isnt sufficient
doesnt have enough transmit power
or even the right antenna
trying to find that old project with alpr
found it
@tulip oracle lel
@POST
@Produces({MediaType.APPLICATION_JSON})
@Consumes({MediaType.APPLICATION_JSON})
@Path("image")
public CarInformation getCar(@Valid CarImageRequest model) {
byte[] bytes = model.getBytes();
log.debug("Image Size: " + bytes.length);
String vrn;
try {
vrn = vrnProvider.getVRN(bytes);
} catch (IOException e) {
throw new InternalServerErrorException(e);
}
log.debug("VRN: " + vrn);
AutoTelexData data = telex.getDetails(vrn);
CarInformation information = new CarInformation();
information.setTelexData(data);
information.setVrn(vrn);
return information;
}
that VrnProvider is where the magic happens
Yeaa
/**
* Provides VRNs from an image
*/
public interface VrnProvider {
/**
* Gets the VRN from an image
* @param image the image
* @return the vrn
*/
String getVRN(byte[] image) throws IOException;
}
magical interface
@Override
public String getVRN(byte[] image) throws IOException {
File file = writeFile(image);
file.deleteOnExit();
return getVRNFromFile(file);
}
_>
@Override
public AlprData process(String file) throws IOException {
Runtime runtime = Runtime.getRuntime();
Process proc = runtime.exec(exec + " -j -n 5 -c " + region + " " + file);
try {
int exit;
if ((exit = proc.waitFor()) != 0) {
throw new AlprException(exit);
}
} catch (InterruptedException e) {
throw new IOException("Failed to load alpr", e);
}
BufferedReader reader = new BufferedReader(new InputStreamReader(proc.getInputStream()));
return gson.fromJson(reader.readLine(), AlprData.class);
}
yes because its a bodge
_>
it just calls shell to do it
exec is the executeable of ALPR
and -j makes it dump json data in terminal :D
ALPR didn't have a straight API that you could use?
it does
but we were working on windows, macs and linux machiens to develop this
getting this to work with maven & native libs
was too much effort.
so we just installed it as a package and used the binaries instead of JNI bindings
Ah fair enough lol
write image to file, call ALPR to give it some estimates
it has a % of how sure it is
it just sorts through those, using legal license plate patterns in that country
for the netherlands we had
{
"patterns": [
"^[A-Z]{2}[0-9]{2}[0-9]{2}$",
"^[0-9]{2}[0-9]{2}[A-Z]{2}$",
"^[0-9]{2}[A-Z]{2}[0-9]{2}$",
"^[A-Z]{2}[0-9]{2}[A-Z]{2}$",
"^[A-Z]{2}[A-Z]{2}[0-9]{2}$",
"^[0-9]{2}[A-Z]{2}[A-Z]{2}$",
"^[0-9]{2}[A-Z]{3}[0-9]$",
"^[0-9][A-Z]{3}[0-9]{2}$",
"^[A-Z]{2}[0-9]{3}[A-Z]$",
"^[A-Z][0-9]{3}[A-Z]{2}$",
"^[A-Z]{3}[0-9]{2}[A-Z]$",
"^[A-Z][0-9]{2}[A-Z]{3}$",
"^[0-9][A-Z]{2}[0-9]{3}$",
"^[0-9]{3}[A-Z]{2}[0-9]$"
]
}
this was a config file, because every few years government adds more
@tulip oracle omg. lmao. I just checked some of the older sources
it has to prepare an email as well
I used JSP for this O.o
haha, say what you will, but it looks clean.
Lol
taglib?
Tags are keywords in JSP to call upon functions
things like profile:gender()
are JSP tags
JSP? I don't even JSP lol
Oh so a template
But hey it works right? thats all that matters
Yea I've heard of handlebars
Barely touched frontend development tbh
Gotta get around to messing around with it
Wanted to check out vue.js
at my workplace they use https://mithril.js.org/
This mithriljs doesn't need to compile to like a bundle.js?
yep
So why your work picked this particular library and not the other stuff?
like vue, react or even angular
leightweight
and you can reuse components you make with mithril, in other applications
that powershell doesn't know about node
wdym
well, you presumably installed node
and you're trying to use that node in a power shell that does not know where that node is installed.
so u r saying either I have installed it in the wrong path or it is an old version of node.js software?
@sly moat powershell, pretty sure commands have to be prefixed with ./node
Need to add node to the PATH most likely in windows, and then close any powershell/cmd/apps that use it like VSCODE
@bitter notch yes but calling executeables from PATH still needs a prefix
it thinks its a PS command otherwise
oh I see
node in powershell just opens the node prompt
@bitter notch its same shit with the JDK on windows
and maven too
on linux that stuff works out of the box
no need for a path, if you can use /bin
Yeah, I cheated and added a C:_PATH to my path where I install anything i want in my path lol
huh
@bitter notch switching versions also very easy with update-alternatives
JDK 8 or JDK 14
Hi. Iโm wanting to learn swift. Is there any good free service or tutorials to start. Btw I already html and Iโm proficient in python.
To learn Swift I ended up using the Apple SwiftUI tutorials and learning the rest of the language based on need
no i used xcode
however if you have no interest in UI design or dont have a mac then you can use the new swift for windows
but xcode was purpose built for swift so i strongly recommend it if you have access to a mac/hackintosh
I've been trying to compile this https://github.com/MJoergen/mchess but I'm getting collect2.exe: error: ld returned 1 exit status every time I do so. Anyone that could help
I tried doing it through command prompt and a few times with visual studio code
what quora
wdym
I used the mingw g++ compiler and tried the gcc but didnt work and then VScode
Im pretty sure vscode also used the mingw g++ compiler
lol idk whats wrong
did you compile the main.cc file
idk wtf is wrong
I do g++ main.cc and this is what comes up
I tried but it was too long and I couldnt bother to take a pic
'i686-w64-mingw32-g++' is not recognized as an internal or external command,
operable program or batch file.
how do I do that
@nocturne galleon from what you posted in that textfile
Seems you haven't included your library path
undefined reference to operator<<(std::ostream&, CBoard const&)
ld is the linker
it links your compiled code to the libraries it uses
I'm not the guru for C++
Only C/C++ I've done was on linux, and that works out of the box with no fuss
which depends on the other sources, which he didn't compiled (and linked)
That has all the things you need for compilation
The makefile actually uses mingw
on windows, that is
Compiles just fine btw
git clone https://github.com/MJoergen/mchess.git
cd mchess
make
@nocturne galleon seems to work fine for me: https://i.imgur.com/hJgFgP1.png
yeah it works with the make command
on linux just fine
@warm sleet
How do I do that on windows
@nocturne galleon you need make
I'm not so sure which one
cmake for windows most likely
I've only ever compiled C on windows once
saw how horrid it is
and went to linux xD
Yeah I have a linux virtual machine now that I have a better computer but I used to dual boot
@nocturne galleon http://gnuwin32.sourceforge.net/packages/make.htm
make {whatisit}
yeah I am currently reading that
the lengths one has to take to get compilation/development environments going on windows, is why I use it strictly for gaming
I just feel like all my development skills go down the drain if I try to do this on a windows box
Yeah I am kinda new to programming but even I noticed how much smoother linux was when I was trying to get tensorflow to work on windows for about 10h and then go it working on linux after about 1h
@nocturne galleon windows is consumer platform, thats what sets linux appart
prosumer software, but requires a bit of know-how to fully utilize
I've been using linux on my daily driver for about 6 years now
yeah I would use linux if all my games would run there
I never want to go back.
It has never crashed in those 6 years
If I turn it on, I am always confident that it will boot
when I shut down my gaming desktop and it says "Windows is installing updates"... I always get nervous
Well I guess the ubuntu distro is pretty user friendly. Only thing that could be a problem is downloading drivers but they've made this command to auto download all the necessary drivers so its still pretty smooth
xd
What
you dont need to install drivers on linux
thats what linux is.
its 80% drivers ;)
wifi drivers, graphics drivers
lol
"Fuck you nvidia"
I hate one thing about the ubuntu distro right now and that is that every time I update it, like for example the kernel. After I update all the drivers are gone and I have to download them again
DKMS
can solve that
thats how I have nvidia drivers for my hybrid graphics setup on laptop
even with that, you still need to restart to switch GPU.
because PRIME sucks.
DKMS links the binary driver to the kernel headers, when you install a new kernel
DKMS then loads them as a kernel module when you load it up
I dual boot on my laptop but I run it on virtual machine on my desktop since I dont really do any heavy work that requires all my pc power
Dynamic Kernel Module Support (DKMS) is a program/framework that enables generating Linux kernel modules whose sources generally reside outside the kernel source tree. The concept is to have DKMS modules automatically rebuilt when a new kernel is installed.
Ill look into that
I forget how I installed it
but ubuntu has guides on how to install it properly
or maybe debian guides
@nocturne galleon linux doesnt have "configuration" in the sense that windows has it
if you want to "configure" linux, you have to configure it with make, and then recompile it
its bit more advanced, but even that. is less than 2-3 commands
with make menuconfig
you get this ^
There's literally 1000s of configuration fields
cool
settings are hardcoded into the binary
yeah Im not that advanced as a linux user. Just started out couple months ago
eh, you barely need to re-compile your kernel yourself if you're just an average power-ish user.
@vestal glen I tossed out bunch of drivers I do not need, everything else is provided as a module
and also made the kernel preemptible
because its only a 2 core system. desktop tends to freeze/lag when system is under load
kernel preemption reduces performance, but makes userspace take priority over kernel code
@warm sleet "Nvidia, fuck you"*
GNU+Linux
if I am creating an updater for my program, it has to grab the new files off the internet, how should I go about it? an SFTP connection? or stream the data through TLS or something?
that's a super generic question
do you mean live patches for an application you're writing?
basically the way discord does it, when the user opens it, it checks for updates, if there are some, it will install them
I currently have implemented the ability for the program to run the update software, which will then reopen the program after faking to update it, since I don't know how to go about that yet
Though I personally haven't used it, you could look into Squirrel @nocturne galleon. It's like ClickOnce but Worksโข
https://github.com/Squirrel/Squirrel.Windows
discord is an electron app
so discord's version of updating is downloading new javascript files
really?
really
you can
all your web browser does is download HTML/HTML5 documents
and then loads them
huh
sometimes it downloads a ton of javascript files
I thought it just downloaded the content of the html page and left it in memory
if the end developer is cool it downloads a WASM file
it only does that if it's a static web page
hmm
well mine consists of 2 executables
the program itself, and an updater.exe
when the user clicks on the program, it realises there are no arguments passed and so it opens the updater and closes itself, the updater, after updating the program, will open it with the argument "UpdateSuccess", when the program sees it got this exact argument, it will run as normal
honestly this is why web applications are so popular
you basically want to add hot-fixes to your application
so the application that basically is just a health check, that would have to do a curl request to a web server
and download your new updated executable
you can download a file on http/s?
uhh
don't question it
hey, it says Hyper TEXT transfer protocol, how am I meant to know it can do files?
by providing a Content-Disposition
HTTP can do binary and text
Content-Type and Content-Disposition help in the client context to resolve
Content-Type just holds information on what kind of file you are requesting
and Content-Disposition is used for things like file-downloads in a browser, so it doesn't open a 2nd tab
@nocturne galleon in essence, its a text based protocol.
GET / HTTP/1.1
Host: google.com

Bruh the only thing Iโve done with web is create <body>hi</body> I donโt know shit about it
fun fax
text can mean whatever you want it to with computers
if unicode is defined as text (which it is)
it literally means anything
just cat a binary file
there's bound to be some actual characters in that
the rest is mostly gibberish, control keys and whatnot
or misaligned literals
making a logic circuit simulator. not gate go brrrrrrrr
added the rest of the basic gates ๐
Nice spaghetti
grid = [["O", "X", "X", "X"], ["X", "X", "X", "X"], ["X", "X", "X", "X"], ["X", "X", "X", "X"], ["X", "X", "X", "X"], ["X", "X", "X", "X"]]
'''
print(grid[0])
print(grid[0][0])
['O', 'X', 'X', 'X']
O
'''
# Define grid, starting position etc ---
# Check new positions are valid ---
# Move "O" to new position
# Replace old "O" with "X" ---
current_pos = [0, 0]
new_pos_x = int(input("Enter X co-ordinates: ")) + 1
new_pos_y = int(input("Enter Y co-ordinates: ")) + 1
pos_valid = False
while pos_valid == False:
if new_pos_x != current_pos[0] and 4 >= new_pos_x and new_pos_x >= 1:
print("Nice")
if new_pos_y != current_pos[1] and 4 >= new_pos_y and new_pos_y >= 1:
print("Cool")
pos_valid = True
new_pos_x = int(input("Enter X co-ordinates: ")) + 1
new_pos_y = int(input("Enter Y co-ordinates: ")) + 1
new_pos_x -= 1
new_pos_y -= 1
grid[current_pos[0]][current_pos[1]] = "X"
grid[new_pos_x][new_pos_y] = "O"
for i in range(0, 5):
print(grid[i])
I have this problem for my Computer Science A-Level, the while loop isn't breaking when both of my debug print() statements are tripping, therefore updating the while loop condition. But the loop doesn't seem to be breaking
okay
instead of just using your code which has weird control flow
use a finite state machine diagram
use a finite state machine diagram
Never heard of it
it's a way of expressing logical connections between code segments without using code
so people can communicate about programs in a language agnostic way
everyone understands pictures
here is an example of a while loop as a finite state machine
It's the fact that Python won't break the loop even though I'm telling it to break that I'm struggling with
the fact is python has unbelievably weird formatting rules
in C,C++,Golang, and Rust we have curly braces for control flow
to eliminate syntax
your logic makes no sense to me
Yep, I prefer braces
and probably a ton of people on this server
But I like python
Yea diagrams easily
@hollow basalt you're wrong
@nocturne crypt how am I wrong for my preference
This isn't a proper program, it's some tiny thing my teacher wants us to write

@hollow basalt only program with yaml
Then create an interpreter for python with braces
from __future__ import braces
no one wants to do that
I'll take one for the team
so seriously if you want help make a FSM
with draw.io
for example
because i don't think it's possible for someone who isn't you to determine if it's a logic error or not
It's not the logic I'm struggling with, an FSM would help with logic.
Dunno, FSM might give you a better perspective
Bruh why are you trolling
my stand speaks!
I fixed it by replacing pos_valid = True with break
No idea what was causing it but oh well
Dah
Dah
@raven roost your origional code works correctly, including the way you break out of the loop, its just ordered incorrectly
this is probably more what you wanted, ```py
grid = [["O", "X", "X", "X"], ["X", "X", "X", "X"], ["X", "X", "X", "X"], ["X", "X", "X", "X"], ["X", "X", "X", "X"],
["X", "X", "X", "X"]]
'''
print(grid[0])
print(grid[0][0])
['O', 'X', 'X', 'X']
O
'''
Define grid, starting position etc ---
Check new positions are valid ---
Move "O" to new position
Replace old "O" with "X" ---
current_pos = [0, 0]
new_pos_x = -1
new_pos_y = -1
pos_valid = False
while pos_valid == False:
new_pos_x = int(input("Enter X co-ordinates: ")) + 1
new_pos_y = int(input("Enter Y co-ordinates: ")) + 1
if new_pos_x != current_pos[0] and 4 >= new_pos_x and new_pos_x >= 1:
print("Nice")
if new_pos_y != current_pos[1] and 4 >= new_pos_y and new_pos_y >= 1:
print("Cool")
pos_valid = True
new_pos_x -= 1
new_pos_y -= 1
grid[current_pos[0]][current_pos[1]] = "X"
grid[new_pos_x][new_pos_y] = "O"
for i in range(0, 5):
print(grid[i])```
with that said, you do a + 1 and -= 1 in there, should probably remove those and use a [0, 4) check
you can also break an infinite while loop here as you dont check pos_valid anywhere, and its always true after that while loop, so, you are basically doing exactly that
while true do

end
hey! does anyone know how to send emails with python?, ive had a few attempts at it but it doesnt ever seem to work.
what have you tried so far
one sec
import smtplib, ssl
port = 465
email here, password here = read_creds()
recieve = sender
message = """
Subject: Python Email Tutorial
This is from python
Romy
"""
context = ssl.create_default_context()
print("Sending")
with smtplib.SMTP_SSL("smtp.gmail.com", port, context=context) as server:
server.login(sender, passw)
server.sendmail(sender, recieve, message)
print("Email sent")
if only people use codeblocks

what's the error
based on my knowledge, google requires specific configuration to work with SMTP
because SMTP is "less secure" method
EHLO instead of HELO
@hollow basalt you ask the SMTP server to upgrade to SSL
initial conversation is unencrypted
SMTP used to work, now it's disabled by default
@nocturne galleon Got it compiled on mingw, I tried using mingw version of make, I think you have to install this through the mingw installer if I recall correctly - this is located under MINGW_INSTALL_PATH/mingw64/bin folder . Didn't work for me either as that I don't have this other program called "sed" installed.
Then again you don't need to use make or the included Makefile. Just observing the Makefile, its barely got any source files that need to be compiled so you can just simply make a shell/batch script and compile it in one line. Just create a batch script with the following:
g++ -Wall -Werror -static-libgcc -static-libstdc++ -O2 -o mchess main.cc CBoard.cc CMove.cc ai.cc CMoveList.cc
Note: You may need to add #include <ctime> at the top of main.cc as I had to do that as well (I think #include <stdlib.h> on linux includes it by default)
@warm sleet cmake is actually a Makefile generator, it reads from CMakeLists.txt and automatically detects the build environment - compilers, library locations, etc and encompasses it into the Makefile. It helps avoid issues where in the Makefile I tried to run had this CC = i686-w64-mingw32-g++ <--- If you didn't have this exact compiler, it wouldn't even compile and would require modification on your part
@tulip oracle ahh, I wasn't aware of that
Any C I've done previously, was either with make, or CMake (but generated with CLion IDE)
Yeaa, its why I like CLion IDE a lot, it integrates sooooo well with mingw and cmake. It does make programming on windows easier.
@tulip oracle I primarily do my work in java
and IntelliJ just offers a level of integration, I've not seen on any other IDE
Couple years ago, they had their own build system
but its fully maven integrated now, which is amazing.
Previously only Netbeans offered this
JavaEE, Webservices, Databases, and plugins for any other language/markup you are using
All in one place
Yeah most of the Jetbrains IDEs are really well thought out
Really impressed with Android Studio too, which they made as well
WebStorm is the only seperate IDE I have next to CLion and IntelliJ
mostly because, WebStorm Debugger integration, somehow not able to get it to work the same way in intelliJ
The filewatching stuff with transpiled code, somehow a big iffy with IntelliJ + NodeJS plugin
mmm work in progress I guess?
Or I am missing some plugins
meh
I got complete jetbrains pack anyways
@tulip oracle ahh yes, and the git integration :D
I used to only need a client for git, to get the little brand-graph visualization
everything else I do with terminal
but IDEA has that built in
submodules, in conjunction with maven modules, works like a charm
CTRL + K
in IDEA for "new commits"
SourceTree I ditched completely
slow ass piece of junk
Its actually that slow huh?
Yes
I had no problems with it tbh
yeah
git is fast, sourcetree is not
if you really need a 'gitflow' workflow
you can archieve the same thing, with a handful of shell scripts
or. even better.
use git hooks.
Unless i decided to use WSL for windows 10
any scripting I do on windows, I just have a .sh and .bat file
the bat file, calls bash -c
so I dont have to fuck around with windows command
@tulip oracle WSL is the biggest piece of shit I've ever used
It lasted a whole week on my system
Whats wrong with it?
then a windows update came, and the entire WSL instance I have is broken
packages unable to be fetched
WSL2... now that was even worse
WSL2 I got filesystem reads of about ~45MB/s
on an SSD that can push 500MB/s
Just, putting linux in a subsystem of windows, is just.. wrong on so many levels
ewww what
its WINE, but worse
Thats hella broken then
WSL is not a compelling argument to use windows for development
any developer who needs a linux environment, will either run a VM, or a dedicated system
yea was a bit confused you saying compelling argument haha
its just microsoft's lame attempt to keep developers on the platform
because once developers leave your platform, the platform is dead.
Linux users will never use Azure
My friend got like paid training for Azure and was offered like a shit ton of credit to mess around it too
I guess they're trying to peddle it to devs
A lot of platform dependencies huh?
What would you recommend, linux in VM or dual boot?
Linux host
Just ditch windows
or put it in a VM
That's what I did for my development machine
But but mah gaemz lol
Windows desktop for games
my laptop would be illsuited for windows anyways
its dual-core i7 5500U with 8GB ram
I got all kinds of kernel patches on my system, to make it useable
like kernel preemption, some compiler optimizations
it idles <1% cpu
and only if you start up a big program, does it spike 100%
Battery life must be improved alot
weeeellll
No lol?
lmao
yeah..
Lost its capacity
Its got hybrid graphics with a GeForce 940M
First of all: hybrid graphics suck complete ass
and second: ASUS cannot design laptops.
The GPU and CPU shared the same heatsink/pipes
With GPU enabled, Idle temps @ 61C
with onboard: idles @ 31C
Whoa thats a huge diff
max load cannot even be archieved with GPU enabled, because it throttles itself to death
@ 104C
with onboard, max load @ 80C
which is fine
Thats pretty insane...wow
@tulip oracle lol and its useable, after some tweaking
imagine what it was like, out of the box with windows
it had two storage devices: 500GB HDD, and a 24GB SSD
the SSD was ment to "speed up" the HDD
but it was a crappy Kingston SSD that did maybe 250MB/s
and the caching solution, was a software service running in windows
often consuming >50% cpu
Wtf lol
Its one of those SSHD?, like you can't access the SSD directly but its used as a cache right?
if its draining battery, and being unuseable
no no
two seperate sata devices
no chipset level magic, pure software
Oh okay
not having a caching service, would have been more performant
yea gotta disable that shiet
I use the 24GB ssd it has, as a 'vault' now
luks volume with a tiny distro on it
thats where I do things that aren't 100% kosher
luks?
The Linux Unified Key Setup (LUKS) is a disk encryption specification created by Clemens Fruhwirth in 2004 and was originally intended for Linux.
While most disk encryption software implements different, incompatible, and undocumented formats, LUKS implements a platform-indepe...
LUKS acts as a partition, that when decryped, holds one or more partitions
so you have 1 partition on your disk, and all your regular filesystems inside that LUKS partition
idk, this stuff is alien technology on windows
Is the encryption necessary?
linux just uses the device mapper for this
@tulip oracle its like bitlocker on windows
except it doesnt suck
Ah fair enough lol
If you want full disk encryption, then you can use luks
Never really bothered with any encryption tbh
If you boot a luks system
you get a black screen, with a password prompt
you enter password, then it can boot linux
So does that mean theres two separate logins you need to do:?
yeah, one is disk encryption
One for decryption and one for the actual distro?
and the other is regular useraccount
I see
But I also encrypt all my external storage devices
HDDs and USB sticks are all encrypted
on big external HDDs, I sometimes make two partitions
one NTFS (for windows) and one LUKS (with encryption)
windows cannot read LUKS
Pretty much isolated yea
if you plug in a LUKS encrypted drive to windows
first thing it suggests: Do you want to format?

Lol
To a user, unaware would be like I can't read this HDD
Time to format this shit
yea
so you put an NTFS partition at the start of the drive
windows detects it
and doesnt ask further questions
it shows up under partition manager as "RAW"
@tulip oracle cryptsetup luksSuspend
thats the panic command, if the feds knock on your door
lmao
it pauses the volume
and flushes the key from memory
so you cannot 'deep freeze' the ram with computer forensics
Do you have alot of stuff to protect/hide?
Not really lol
I know I don't, people could go through my files for all I care
and at gunpoint, I'd probably give up the details
lmao
don't want that all over the place
Hey we call those "backups"
well
its not a backup
if it has the name of a known redistributor in the filename
like so many torrents do
most of the movies I have pirated though, are pretty old
some of em, even in monochrome color (black/white)
lol
Probably still one of my old time favorites
Tis beyond my time
Its satire about the whole 'commie conspiracy' and mutually assured destruction
its worth watching
its quite amusing :D
Its beyond my time too
Mmm so this is what is in your encrypted drive
that, with another 300GB music
_>
@tulip oracle on my server, I also use luks
there's customer files on that, so reasons
but that is raid1 with luks
using btrfs
two disks, both with luks, using the same key
@warm sleet
Good, now tell me the key ๐
Just need access to a super computer to bruteforce that
cannot brute force it either
Lol
youd need a supercomputer the size of the galaxy, and then some
Yea like with a search space of 2^4096
Supplement to the cryptocurrency video: How hard is it to find a 256-bit hash just by guessing and checking? What kind of computer would that take?
Cryptocurrency video: https://youtu.be/bBC-nXj3Ng4
Home page: https://www.3blue1brown.com/
Several people have commented about ...
^ to give you some idea
Yeaa I've seen his vids
you need a gazillion kilogoogles
crypto mining is biggest idiocy I have ever seen
blockchain is a cool concept, but the implementation calls for wasting power.
and with global warming and all, its a shame
There are blockchains designed to not use much power
@vast echo tell that to bitcoin
Bitcoin is not one of them
yet its the one that everyone wants
and for the foreseeable future, we're stuck with it
Check out Lightning Network?
yeah, that addresses the scaling issues
to get around the limit of amount of transactions/block
bitcoin has a long block timer too
10 minutes
litecoin scales better, with 2 minutes
but still has same issues
afk ,dinner
https://gyazo.com/27ce2ae880095931b8fb35f517790272
Firstly, how would I declare the .map, and what is the issue? I can't seem to find it.
And then why does the final bracket on "24, 1" say it is undeclared, even though it is declared at the top of the block.
This is the error message when I try to run it
Anyone using GodotEngine here?
No but always been tempted to have a look at it. I currently only use UE4.
How would you code something like this? Basically a Welcome Message, it autoroles you, and then when you do a .agree command it takes the old role, and gives you another one.
@cursive laurel it's really nice, I'm currently working on multiple project with it and I like it a lot ๐
yo anyone know what type is used for the IPAddress in c#?
nevermind, found a method for converting it

in c# it's its own class
for going to/from string, you need to use the parse/tryparse methods
@cinder kraken some datatypes in C# are structs
but would make sense that IP is a class, because their spec says it does both v4 and v6
until dotnet 2 it was a struct
does anyone know much SQL can't get this statement to work "CREATE TABLE Suppliers(SupplierIdNo INT,SupplierName VARCHAR(30),SupplierEmail VARCHAR(120),SupplierAddress VARCHAR(300),SupplierPhone INT(11),SupplierWebsite VARCHAR(100),PRIMARY KEY(SupplierIdNo))"
CREATE TABLE foo (
bar VARCHAR(100) NOT NULL,
CONSTRAINT pk_foo PRIMARY KEY (bar)
)
i'll try that
depending on what sql engine you are using ,you may also put PRIMARY KEY directly by the field
but that is bad practice
usually, make a named constraint pk_tablename
foreign keys same way: CONSTRAINT fk_name FOREIGN KEY (keys) REFERENCES othertable(field)
error?
well it's through visual studio and it's for my A-Level coursework so i can't use any packages so i have a pre defined executeSql() method
so it won't give me error codes
or informstionb
do you not have an sql console?
my method in c# works like this
do you even know what kind of sql engine you are using?
you don't typically execute DDL in code
No however i have already created a table that works
you do that with a database script, and only use DQL or DML in code
I hope you know what DQL and DML are
this is one that works
no not really i don't know much other than the basics for SQL
yeah, but do you know what server your program connects to?
If you can just use an sql workbench, and run queries on the fly
thats how you test and write your queries
once they work, you put them in your code
is this it Provider=Microsoft Jet 4.0 OLE DB Provider
the whole connection string is ""private const string CONNECTION_STRING = @"Provider=Microsoft Jet 4.0 OLE DB Provider;Data Source = " +
EXAMPLEDB + ";";
exampledb is StockDatabase.mdb
I thought people no longer used ADO.NET
whatever your course is teaching you
that's pre 2010 bullshit
honestly we were learning delphi last year so that's no suprise to me
@upper perch honestly, if you want to get a good feel for SQL
just download SQL Server Express
it comes with management panel
can even be made to work with your code
takes minor adjustments to the CONNECTION_STRING
ok thanks will have a look
Get started with Microsoft SQL Server downloads. Choose a SQL Server trial, edition, tool, or connector that best meets your data and workload needs.
I had to use MS Access during my courses on databases
@upper perch kinda need to get some output from the sql server xD
ah fair lol
Alright will keep in ming
ADO expects you to configure the data source in the operating system
and that connection string, uses ADO to get the actual datasource through the OS
windows is convoluted in this area. its beyond stupid how microsoft does this stuff
typically
@upper perch this is the string you'd use for SQL server 2019 Server=myServerAddress;Database=myDataBase;User Id=myUsername;Password=myPassword;
IP, database, username & password
in your .NET project. may have to add a nuget package or reference to the Microsoft.Data.SqlClient
alright cheers mate
@upper perch https://i.imgur.com/Dxhzl1j.png
This is what you want
class Program {
private const string ConnectionString = "";
static void Main(string[] args) {
SqlConnection connection = new SqlConnection(ConnectionString);
connection.Open();
SqlCommand command = new SqlCommand("query", connection);
command.ExecuteReader()
}
}
minimal amount of code ^
"query" is where your sql goes
ExecuteReader() returns a table reader which you can use to retrieve rows from the query result
Yeah i had that as its own method to execute the SQL statements
anyways i have fixed the statement know turns out it was because VARCHAR can only hold up to 255 characters (I had 300) and i was trying to limit the integer through INT(11) which doesn't work so i switched to VARCHAR instead. Thanks for your help anyways tho @warm sleet
@upper perch usually INT for 32 bit, and BIGINT for 64 bit
you can also do unsigned numbers, with UNSIGNED INT
VARCHAR has a limit of 8000
beyond 8000 characters, you just do VARCHAR(max) for maximum of ~2GB
im working on a copying program, and im having trouble with glob patterns, how do i get a pattern that matches everything that is not in a node_modules directory?
my current pattern is !**/node_modules/**/*.*, but it only seems to work on some glob pattern testers
! usually only makes an exception for already excluded things
any linux mint users? i'm trying to install a game via steam on a second ssd but for w/e reason it keeps saying the disk isnt writeable :c
OMG nevermind after the 15th time I got it to work โค๏ธ
idk what I did differently
yeah idk
is gitlab free?
is gitlab free?
@nocturne galleon they have a free version https://about.gitlab.com/pricing/
cause it said the self-hosted is fully featured and free but there is a pricing guide for the self hosted, which has me confused
an article reviewing it said this
but the site says this, implying there is a payment structure for self hosted
wait nvm yeah I see now, you can get more features self hosted for a subscription
so reading what they say, I dont actually need any more than the free version for a solo kid
Hey any remmendations for free web hosting?
your own pc
Hey any remmendations for free web hosting?
@dusty ermine
Absolutely free web hosting with cPanel, PHP & MySQL for a stunning blogging start. Get free website hosting together with a free domain name at no cost at all!
your own pc though
also you can self-host gitlab on your own hardware
and just deploy it that way
@nocturne crypt I wouldn't recommend gitlab to smalltime users.
gitea is much faster and less resource heavy
gitlab ships with a lot of bulk and middleware
@nocturne galleon derivative?
i like gitea
You'll have to do this calculation yourself
scipy has a misc module, this should have a derivative() operation
@nocturne galleon not really no
a graph is a type of presentation
which assumes you have the raw data ;)
doesnt matplotlib just take an array of values ?
I don't understand your question
you want to change the scaling on the y-axis?
your lowest value, which is at x=0, is 780
wat.
computer presents that graph
it doesnt see shit
what is it you are trying to archieve lol
because I am confused
cannot be done
well yes
the reason its not been done
is because nobody ever needs this
extracting data from a generated graph, sounds wrong on so many level
because of inaccuracy
wat.
machine learning is a buzzword
it carries no meaning
10% profit in 12, wtf are you talking about lol
why does this sound like a get rich scheme
bruh
if you want to interact with stock exchange data
use their API
not try to machine-learn-render their graphs
APIs are for programs to talk to other programs
you want your program, to retrieve data from the stock exchange
Ahh yes
obviously
uhhh
their services cost money too ;)
Why not spend money...to make money lol?
@tulip oracle yeah but we're trying to crack the secrets of the universe here
how to make millions using nothing but a wallet full of flies
Nah
no lol
Have you paid any attention in the last 5 minutes?
Then I cannot help you further
You use an API for this kind of stuff.
Some of them, yeah... require paying for it
Then I cannot help you further
Web scraping, web harvesting, or web data extraction is data scraping used for extracting data from websites. Web scraping software may access the World Wide Web directly using the Hypertext Transfer Protocol, or through a web browser. While web scraping can be done manually b...
not try to machine-learn-render their graphs
@warm sleet did someone actually wants to get the data from the graphs?
@nocturne galleon what you described, sounds like Scraping
Its a crude form of reading data from a page
without an API
scraping of images.... IMPOSSIBRUUU
ya
but he said machine learning ๐
@tulip oracle yes. There are efforts using machine learning and computer vision that attempt to identify and extract information from web pages by interpreting pages visually as a human being might.[4]
but trying to scrap stock exchange data off a rendered graph
what if its about millions of dollars
1 pixel difference, rip 100k
Possible but might require tons of effort
1 pixel difference, rip 100k
this tbh
any margin of error is money burned
๐ธ
Yes, so you NEED accurate data
A slight deviation in output from a neural network. gg your savings
kk
@hollow basalt cavalry was notified for cleanup

since the original messages were still there, and not deleted

@hollow basalt any luck on the ac3 yet?
Learning some Lua
Anyone know python that can help me?
what do you need help with?
Ill dm you
yikes
Smooth
I know a little bit of python, but I'm not super well versed
@reef tangle i will help to the best of my ability
i love tab errors

