Source code is any collection of computer instructions (possibly with comments) written using some human-readable computer language, usually as text.

learn more… | top users | synonyms (1)

-5
votes
0answers
25 views

How to secure code of Java web project? [duplicate]

I am working on one application java/jsp application. I want to package this project in a way so that ONLY intended tomcat can decrypt and deploy it ? What are the possible ways to achieve this ?
1
vote
1answer
26 views

In gitlab, should we close a merged MR?

In gitlab, there is Merge Requests (MR) like in github there is Pull Requests (PR). If the MR is rejected, sure, we close it. But what if the MR is merged ? In that case the button to close the MR ...
8
votes
2answers
248 views

Apollo-11: Using inclusion instead of a linker

Recently digitized and turned into a repo, the original Apollo 11 guidance computer source code has been made available for viewing on Github. In MAIN.agc, the repo author comments that they ...
-2
votes
2answers
77 views

Translation of a project from one language to another

If I wanted to turn a Java game into Lua, how could I do it? I'm thinking that you could have a program read the assembly language behind two programming languages, find the patterns, attach them to ...
1
vote
3answers
165 views

What's code that's not a part of API called? [closed]

In a library with many code, some of them being the API which user would use to interact with the library, what should I call the rest of the code which is not part of the API directly? In other ...
4
votes
1answer
115 views

Should the ability to locate where code is being used be a consideration?

I was modifying a class whose job is to load other classes from the same directory. Basically, everytime a new class is added you need to add a new CommandClass; statement to this class for it to be ...
0
votes
2answers
102 views

Modernize a compiler, late switch of generation-paradigm

Have been hired to modernize an old binary compiler that has been forgotten since a few years by people who have died already. The compiler has a parser, an objectmodel and a generator of ...
4
votes
2answers
145 views

Should I have a 'dev' branch separate from a 'production' branch?

I recently set up my staging and production server environments on Heroku and everything is working great. Through Heroku, you can deploy from a Git branch - e.g. master or my-feature. This got me ...
1
vote
1answer
98 views

Sharing code with API vendor for review without giving them access to the server or repo

A private company allowed me to use their API to make REST API calls (using Basic Authentication) in my application's server side. They also asked to see my implementation before I can go live. From ...
0
votes
2answers
75 views

Can I release software under the GPL if it must be built with a proprietary compiler?

The compiler doesn't leave its own code in the software or link proprietary libraries with it, the source code is exactly the same one I used throughout the development process, everyone is free to ...
-2
votes
2answers
124 views

Are there coding standards for whether procedural programs should have source code listed top-down or bottom-up? [closed]

Let's say I have a basic procedural program which is well structured into decomposed functions. For example, a main() function which calls functions a and b, which in turn each call functions c and d, ...
0
votes
0answers
40 views

How to study a big project source code? [duplicate]

I am newly hired in a company department which uses Meteor and React in building projects. As expected, I am required to study the source code regardless of the project size and progress. This ...
2
votes
2answers
140 views

Distributing GPL-ed software with lost source code

Thought experiment. Tom is a software developer. He releases his relatively simple software under GPL. Jerry forks his source code and creates a world savior software with months or years of hard ...
-4
votes
2answers
146 views

How to find all occurrences of a variable within a source code?

The title is pretty self-explanatory. I have a minified JavaScript code (100k+ lines) and would like to find all occurrences of a particular variable so I could rename it to better understand code. Is ...
90
votes
8answers
13k views

Why did BASIC use line numbers?

Why did old BASICs (and maybe other languages) use line numbers as part of the source code? I mean, what problems did it (try to) solve?
3
votes
1answer
157 views

Architecture: API with slightly different behavior depending on the logged-in user roles

How should I structure a piece of code that executes an operation, but may have slightly different behavior depending on, let's say, user roles? Example: My app has a 'manager' and a 'employee' roles....
0
votes
2answers
175 views

How to analyze a code of a web application which is running? [closed]

Joshua Bloch said in an interview that the best way to know and understand code written by others is to read it, mentally or through a debugger. Well, my question is this: is it possible, through a ...
3
votes
1answer
116 views

Do I update the copyright header when i modify the source?

Suppose I were to modify a said piece of code and put it back on github, would I have to update the license header. This is the code(Licensed under the Apache License, Version 2.0): https://github....
0
votes
2answers
174 views

What are good ways to measure project size? How do I compare the size of my project to other projects? [closed]

Background I am currently working for a quite large (relative to what I have done before) hobby project. I would like to compare the size of this project to other open-sourced projects but I cannot ...
1
vote
3answers
309 views

What does it mean to build from source?

I'm trying to install numpy using this. This link opens with these instructions: These instructions describe how to build NumPy and SciPy libraries from source. If you just want to use NumPy ...
2
votes
3answers
217 views

What is the most readable way of passing arguments to the function? [closed]

I'm using JavaScript but the question can be generalized to all the languages. In a nutshell - I'm checking if a browser connecting to my site is a microwave and cater for that accordingly. What ...
-2
votes
4answers
122 views

Best possible way to comment? [closed]

My question is simple, how should I comment during development so that it can be beneficial in the following cases: Understandable for my seniors while code reviewing. Should be able to search my ...
1
vote
4answers
210 views

How to keep documentation up to date and accessible [duplicate]

The problem: Documentation is in code in the form of docs, its in wiki websites, its written down on notes, in diagrams and issue management systems. When documentation is so spread out, how does ...
0
votes
1answer
46 views

Snippets (based on MIT licence) from snippets services

I have question about MIT licence code sources Can I publish code snippets [MIT licence] from site like bootsnipp to my blog? Do I have to include source link to site where I have found that snippet ...
0
votes
2answers
172 views

Process of handing over source code to a customer [closed]

Should I just copy the project files to him? Should I sit and explain the code to him ? If so, up to which level of details? Or do I just tell him where everything is within the solution and not how ...
2
votes
2answers
101 views

Delivering source code - refactor for clean up? [closed]

I'm in the middle of developing an asp.net webforms application to a customer, i've been using DataAccess and BusinessLogic layers in a folder structure within my application, in which my DataAccess ...
39
votes
13answers
6k views

How safe is it to compile a piece of source code from a random stranger? [closed]

Suppose I'm reviewing code that job applicants send to prove their skills. Clearly I don't want to run executables they send. Not so clearly I'd rather not run the result of compilation of their code (...
0
votes
1answer
81 views

Licensing - Restrictive Open Source License OR Custom License [closed]

I have some source code I want to release but I'm unsure of the best license to put on it. From my research such licenses as MIT and GNU are horrible as they offer little to no protection towards ...
4
votes
3answers
153 views

How to display/clarify the licence for code in a blog

Let's say I have a blog available under one of the Creative Commons licences. Such type of licence would be displayed at the bottom of each page with a link to the actual licence, etc.. However, ...
1
vote
1answer
85 views

Should my program be flawless at release [duplicate]

I'm building a big, very complex piece of open-source software, and it's killing me trying to make what I have as "clean" as it needs to be. What I want to know is: If there is an undetected flaw in ...
0
votes
1answer
56 views

Upgrading inherited 3rd party code with changes [closed]

I inherited a php project of 3rd party code with a good deal of company-specific customization lumped on top of it. Now I've got to upgrade it and the person who owned the project is the one I've ...
3
votes
1answer
610 views

Licensing code submitted after job interview [duplicate]

I applied for a job in a small company (~25 employees) on December and after a month the CEO of the company wrote to me that he is interested to interview me. During the interview I got a bad ...
54
votes
9answers
10k views

Bad sign if nobody can comprehend one's code? [duplicate]

If a coder writes code that nobody other than he can understand, and code reviews always end with the reviewer scratching his head or holding their head in their hands, is this a clear sign that the ...
0
votes
1answer
89 views

Return values and exceptions [closed]

I wrote simple function that returns a string depending on which condition is TRUE. Here is my code: private String getMyString() { if(!mStrigMember.isEmpty()) { return mStrigMember; }...
8
votes
3answers
1k views

Is reading javadoc preferable to reading source code to familiarise yourself with a library?

I just came across the following in a lab manual at university: You do need to study the interfaces of the classes by generating the javadoc for them so you know what operations are provided (feel ...
0
votes
1answer
61 views

Where should I put (wrapper) scripts in my source tree? [closed]

I have this software package which installs itself to /usr/local/mypackge, with a bunch of subdirs. In bin/ I have linked code, as ELF executables, in /share/doc I have documents, etc. Now suppose I'...
2
votes
1answer
329 views

How can I encrypt or remove readability of source code before publishing it?

I am working on a collaborative project, for which I have to submit source code, which will be used/embedded in the main repository for re-compilation. Is there any way, I can encrypt the source code ...
59
votes
6answers
6k views

Why aren't there code overviews for open-source projects? [closed]

There are very complex open source projects out there, and to some of them I think I could make some contributions, and I wish I could, but the barrier to entry is too high for a single reason: for ...
-2
votes
1answer
352 views

Is it bad to feel guilty using lots of libraries? [duplicate]

So I'm an android programmer,have been programming for about 3 years,but it wasn't until 5 months ago that I started really taking it seriously. Recently I got my first internship,and I'm happy with ...
3
votes
1answer
464 views

How to Safely Sell Source Code? [closed]

I'm a seller with a prospective buyer for some of my source code. I'd like to structure the transaction so as to protect each of our interests, but there's one aspect that I haven't been able to ...
2
votes
1answer
145 views

Do you maintain your own utilitiy library [duplicate]

So, i've started working as a freelancer and therefore find myself copy/pasting util methods from one class to another. Not good to say the least. I do this on my mobile frontend dev and backend .net....
4
votes
4answers
1k views

Do I have to make source code open, if I use GPLv2 licensed software to derive data

I'm working on a calendar project, on my own. In this project I've to use Swiss Ephemeris. It is licensed under GPLv2 and commercial. With commercial version of license, developers entitled to ...
13
votes
8answers
2k views

When does one hard-code actual data values into the code as opposed to using a DB?

A long-standing question for me has been: when do I store data (actual values) in a database table, and when do I store them right in the code? The untold consensus has typically been as such(*): If ...
5
votes
2answers
375 views

GPL- How much source must be released?

Suppose I have a GPL v2-licensed library that is of interest to a closed-source project (e.g. Wolfram Alpha). If some of my code were used in Wolfram Alpha, or a product that interfaces with Wolfram ...
2
votes
0answers
70 views

Setting permissions issue for admins and lower users in project

I am working in a jsp project an got stuck in a big problem. My project consist of accounts table for super admin, reseller, admin and users for executives and manager mapped in the account ...
8
votes
2answers
6k views

How to do documentation for code and why is software (often) poorly documented?

There are some good examples of well-documented code out there, such as java api. But, a lot of code in public projects such as git and internal projects of companies is poorly documented and not very ...
19
votes
14answers
6k views

How many mistakes does a good software developer make? [closed]

I am currently in a situation where a lot of people criticized me for making bugs (on my first local try - the first time I run the code for the first locally done test - , not on a committed repo ...
3
votes
2answers
224 views

Is it customary for software companies to forbid code authors from taking credit for their work? do code authors have a say? [closed]

The company I work for has decided that the source code for a set of tools they make available to customers is also going to be made available to those customers. Since I am the author of that source ...
1
vote
2answers
383 views

Mechanics of reasoning during programming interviews [closed]

This is not the usual "I don't want to write code during an interview", in this question the assumption is that I need to write code during an interview (think about the level of rewriting the ...
1
vote
1answer
396 views

How does an optimizing compiler react to a program with nested loops?

Say you have a bunch of nested loops. public void testMethod() { for(int i = 0; i<1203; i++){ //some computation for(int k=2; k<123; k++){ //...