Some languages don't care about indentation, developers can write all their code in one line. Apache license requires to add a copyright notice if someone else changed the code, if I only changed code indentation of languages that don't care about indentation, should I add a notice?
- I don't think that changing the style of the code violates any sort of code copyright. It would be different for art.Rohit Gupta– Rohit Gupta2023-04-22 00:16:04 +00:00Commented Apr 22, 2023 at 0:16
- 1Could you add why you want to do this, e.g. is it for some sort of minimization, to put all the code on one line?Brandin– Brandin2023-04-22 15:44:30 +00:00Commented Apr 22, 2023 at 15:44
- 1I use "cargo fmt&&sync" in shell, where cargo is a tool by Rust language developers, fmt means to format the code according to Rust standard format and sync means to write all cached changes to disk.Flan1335– Flan13352023-04-24 09:08:29 +00:00Commented Apr 24, 2023 at 9:08
- Possibly related: opensource.stackexchange.com/questions/12340/… It does not mention the "indentation only" special case in this Question, though.Brandin– Brandin2023-04-27 06:12:53 +00:00Commented Apr 27, 2023 at 6:12
- Can you do just a "cargo fmt" first, and then check using a source control tool, which files were changed by that action? That's one way you might be able to comply with Apache easily "cause any modified files to carry prominent notices". Personally I have no experience with Rust or Cargo.Brandin– Brandin2023-04-27 06:13:52 +00:00Commented Apr 27, 2023 at 6:13
Add a comment |