Questions tagged [file-generation]

31 questions
6
votes
1 answer

php create file and send as attachment without actually creating the file

I know how to read a file on the server and attach it to an email in PHP, but I wanted to know if I could attach a file that is created by my script but not created on the server (kinda like a temp file). So create file in memory and attach it to…
Phill Pafford
  • 83,471
  • 91
  • 263
  • 383
4
votes
1 answer

Generate and download a text file in javascript

All my research so far suggests this can't be done, but I'm hoping someone here has some cunning ideas. I have a form on a website which allows users to bulk upload lots of URLs to add to a list on the server. There's quite a lot of server-side…
Mark B
  • 4,768
  • 2
  • 25
  • 30
4
votes
3 answers

HTML client-side portable file generation - no external resources or server calls

I have the following situation: I have set up a series of Cron jobs on an internal company server to run various PHP scripts designed to check data integrity. Each PHP script queries a company database, formats the returned query data into an HTML…
recursion.ninja
  • 5,377
  • 7
  • 46
  • 78
2
votes
1 answer

Is there an agnostic cli for quickly generating new features and projects?

I'm in the process of building some tools but find myself thinking I'm reinventing the wheel. I'm looking for a cli, preferably written in javascript, that has a config file and template engine. The config file would let you specify projects and…
rob.luton
  • 395
  • 1
  • 4
  • 7
2
votes
1 answer

How to write a large amount of random bytes to file

I need to generate some files of varying sizes to test an application, I thought the easiest way to do so would be to write a Node script to do so. I wrote the following code but the process crashes when the file size exceeds my memory. const fs =…
1
vote
1 answer

Create new files by copying contents of coordinate files into template file

I would like to write a BASH/ZSH script to create a series of input files to run calculations based on a series of molecular coordinate files which have been generated for me. Do do this, I would like to copy the coordinates into a template file and…
1
vote
1 answer

Spring Batch file writing job doesn't stop and keeps running

I have a sample Spring Boot/Batch job I'm assembling together by adopting several online examples that is intended to simulate the generation of an ACH formatted file. I can see the file gets generated, but the job never finishes and the output…
1
vote
1 answer

How to get Styled HTML to print a file with PHP

I was using this: http://softwaremaniacs.org/soft/highlight/en/ to highlight code, as seen here: http://www.u4ik.us/code and if you type in some code and hit go, it highlights it. You can change the colors and all. I was wondering if I could then…
U4iK_HaZe
  • 171
  • 7
1
vote
0 answers

How to calculate png size based on dimension and bit depth

I'm trying to generate white png (jpg, gif as well) files using imagemagick. I have to calculate image's dimension based on size(kb) and bit depth(1). I'm using this command on my windows machine: magick -size "width" x "height" canvas:black…
styopdev
  • 2,604
  • 4
  • 34
  • 55
1
vote
1 answer

Create a MS Word doc based on a template, changing specific parts of it using user provided values

I need to dynamically generate contracts, and for that our HR depart already has some specific templates which only need a few changes (like names, address, phone number, etc). For that reason, I'm looking for a library that will help me with the…
eddy
  • 4,373
  • 16
  • 60
  • 94
1
vote
3 answers

Makefile: order of dependency evaluation

Assume a target foo.tar, that depends on a list of files foo.files, e.g. FOO_FILES := $(shell cat foo.files) foo.tar: foo.files $(FOO_FILES) tar -cf foo $(FOO_FILES) Now suppose that foo.files need to be generated e.g.: foo.files:…
Chen Levy
  • 15,438
  • 17
  • 74
  • 92
1
vote
0 answers

Roslyn Single File Generator Diagnostics

I am using Roslyn for creating Single File Generators. Under certain conditions I'd like to report an error. I am using IVsGeneratorProgress.GeneratorError function to add the error to the error list. However, I also want to have some code…
Nick Polyak
  • 201
  • 1
  • 9
1
vote
1 answer

Generate file by template using maven

I have a directory that contains several children-directories. These directories are being generated by maven assembly plugin. I want to generate the .properties file that contains smth…
Vasilii Ruzov
  • 554
  • 1
  • 10
  • 27
1
vote
2 answers

Library for generating independent windows executable in Java or C++

I am not trying to compile my source code into an executable. Please read before marking as duplicate. With that said, I apologize if this question has been asked before. The countless "how do I compile java | C++ to exe" questions filled up all my…
ApproachingDarknessFish
  • 14,133
  • 7
  • 40
  • 79
0
votes
1 answer

How do flat file content management systems create new .txt files?

I'm most interested in flatpress, since that is the one I'm currently working with. All i had to do with it was remove its 'read-only' status in windows 7. I have zero understanding of what 666 or 777 permissions are. If you have insight into other…
expiredninja
  • 1,397
  • 4
  • 25
  • 45
1
2